Giter Club home page Giter Club logo

Comments (6)

mrgloom avatar mrgloom commented on July 2, 2024 12

About dlib 68 pts model to wflw 98 pts model index mapping:

DLIB_68_PTS_MODEL_IDX = {
	"jaw" : list(range(0, 17)),
	"left_eyebrow" : list(range(17,22)),
	"right_eyebrow" : list(range(22,27)),
	"nose" : list(range(27,36)),
	"left_eye" : list(range(36, 42)),
	"right_eye" : list(range(42, 48)),
	"left_eye_poly": list(range(36, 42)),
	"right_eye_poly": list(range(42, 48)),
	"mouth" : list(range(48,68)),
	"eyes" : list(range(36, 42))+list(range(42, 48)),
	"eyebrows" : list(range(17,22))+list(range(22,27)),
	"eyes_and_eyebrows" : list(range(17,22))+list(range(22,27))+list(range(36, 42))+list(range(42, 48)),
}

WFLW_98_PTS_MODEL_IDX = {
	"jaw" : list(range(0,33)),
	"left_eyebrow" : list(range(33,42)),
	"right_eyebrow" : list(range(42,51)),
	"nose" : list(range(51, 60)),
	"left_eye" : list(range(60, 68))+[96],
	"right_eye" : list(range(68, 76))+[97],
	"left_eye_poly": list(range(60, 68)),
	"right_eye_poly": list(range(68, 76)),
	"mouth" : list(range(76, 96)),
	"eyes" : list(range(60, 68))+[96]+list(range(68, 76))+[97],
	"eyebrows" : list(range(33,42))+list(range(42,51)),
	"eyes_and_eyebrows" : list(range(33,42))+list(range(42,51))+list(range(60, 68))+[96]+list(range(68, 76))+[97],
}

DLIB_68_TO_WFLW_98_IDX_MAPPING = OrderedDict()
DLIB_68_TO_WFLW_98_IDX_MAPPING.update(dict(zip(range(0,17),range(0,34,2)))) # jaw | 17 pts
DLIB_68_TO_WFLW_98_IDX_MAPPING.update(dict(zip(range(17,22),range(33,38)))) # left upper eyebrow points | 5 pts
DLIB_68_TO_WFLW_98_IDX_MAPPING.update(dict(zip(range(22,27),range(42,47)))) # right upper eyebrow points | 5 pts
DLIB_68_TO_WFLW_98_IDX_MAPPING.update(dict(zip(range(27,36),range(51,60)))) # nose points | 9 pts
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({36:60}) # left eye points | 6 pts
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({37:61})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({38:63})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({39:64})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({40:65})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({41:67})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({42:68}) # right eye | 6 pts
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({43:69})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({44:71})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({45:72})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({46:73})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update({47:75})
DLIB_68_TO_WFLW_98_IDX_MAPPING.update(dict(zip(range(48,68),range(76,96)))) # mouth points | 20 pts

WFLW_98_TO_DLIB_68_IDX_MAPPING = {v:k for k,v in DLIB_68_TO_WFLW_98_IDX_MAPPING.items()}

dlib_68_template
wflw_98_template
ibug_300_w_68_point_shape_model
wflw_98_point_shape_model

from lab.

mariolew avatar mariolew commented on July 2, 2024 4

@wywu Dear author, I think the 68-pt definition and 98-pt definition have many pts in common, so I don't think a model trained on the extracted 68-pt data would perform "very poor". I wonder what do you mean by "very poor"? And I'd like to know if I extract 68-pts from the predicted 98-pts, will the results be bad? Thanks in advance.

from lab.

Ivy147 avatar Ivy147 commented on July 2, 2024

Dear wywu,
I have the same question, could you tell me how can I detect 68 landmarks from WFLW dataset?

from lab.

wywu avatar wywu commented on July 2, 2024

Hi, thanks for your interest! Since we do not know the detail of the annotation process of the 68-landmarks of 300W, we do not have the explicit corresponding between 98pt and 68pt. Of course, we can find the possible defined landmark of every point of 300W in 98-landmark protocol. However, we have tried to train one model on the 68pt extracted from 98pt on WFLW and test on 300W, but got a very poor performance because of the gap of the definition of landmarks.

from lab.

mrgloom avatar mrgloom commented on July 2, 2024

In description we have 10000 faces (7500 for training and 2500 for testing) but I only see 6551 jpg files, so I assume that some images have multiple faces on them, is it correct?

from lab.

mariolew avatar mariolew commented on July 2, 2024

@mrgloom Some images contain more than one faces.

from lab.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.