Comments (5)
import numpy as np
import matplotlib.pyplot as plt
from scipy.integrate import simps
def AUCError(errors, failureThreshold=0.08, step=0.0001, showCurve=False):
nErrors = len(errors)
xAxis = list(np.arange(0., failureThreshold + step, step))
ced = [float(np.count_nonzero([errors <= x])) / nErrors for x in xAxis]
AUC = simps(ced, x=xAxis) / failureThreshold
failureRate = 1. - ced[-1]
print("AUC @ {0}: {1}".format(failureThreshold, AUC))
print("Failure rate: {0}".format(failureRate))
if showCurve:
plt.plot(xAxis, ced)
plt.show()
from hrnet-facial-landmark-detection.
May I know, What does errors denote in this context?
Thank you
from hrnet-facial-landmark-detection.
@kshashankrao
Hi, errors is a list that save the mean error of each face image. And the mean error is defined as the average Euclidean distance between the predicted facial landmark locations pi,j and their corresponding ground truth facial landmark locations gi,j.
eg. the test size of COFW dataset is 507, so the length of errors of COFW test set is 507.
from hrnet-facial-landmark-detection.
Hey, thank you for the information. I believe that euclidean distance is calculated by compute_nme function. Should these values be used for AUC or failure (with threshold)?
from hrnet-facial-landmark-detection.
@kshashankrao
Hi, you're right. compute_nme function is used to calculate the normalised mean error of a face image. you can save them and then use them to calculate AUC and failure rate (with threshold 0.1 or 0.08).
from hrnet-facial-landmark-detection.
Related Issues (20)
- Want to run inference on CPU, any solution? HOT 2
- head
- head estimation
- How to acquire labels on own images? HOT 1
- 300W pretrained model weights' name inconsistent with updated model HOT 3
- Could you share with the model file of RACE dataset (106 points)
- So many bugs.....
- how to test this code in other Dataset? such as CelebA and FFHQ.
- Error in loading model trained on 300W dataset HOT 2
- volatile gpu-util=0% when training HOT 1
- Why don't you use Sigmoid fucntion as the last activation function?
- Why do you re-write such "crop" function ? HOT 1
- 300W Dataset Annotation File Detail HOT 1
- How to download the 300W full set? HOT 2
- I want to detect landmarks in real time HOT 1
- demo.py
- What is the aim of "Transform back"? Is it necesary when inference on my images?
- How to modify code for only one landmarks cordinates ,Like I have only one xy coordinates
- How long it takes to detect a image HOT 1
- Confidence Score of Detected Landmarks
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hrnet-facial-landmark-detection.