yfeng95 / DECA

DECA: Detailed Expression Capture and Animation (SIGGRAPH 2021)
Other
2.12k stars 421 forks source link

Unknown error when performing the demo reconstruction #185

Closed AlbertBaichenDu closed 1 year ago

AlbertBaichenDu commented 1 year ago

Traceback (most recent call last): File "C:\Users\alber\DECA\demos\demo_reconstruct.py", line 133, in main(parser.parse_args()) File "C:\Users\alber\DECA\demos\demo_reconstruct.py", line 42, in main testdata = datasets.TestData(args.inputpath, iscrop=args.iscrop, face_detector=args.detector, sample_step=args.sample_step) File "C:\Users\alber\DECA\decalib\datasets\datasets.py", line 71, in init self.face_detector = detectors.FAN() File "C:\Users\alber\DECA\decalib\datasets\detectors.py", line 22, in init self.model = face_alignment.FaceAlignment(face_alignment.LandmarksType._2D, flip_input=False) File "C:\Users\alber\miniconda3\lib\enum.py", line 437, in getattr raise AttributeError(name) from None AttributeError: _2D

ArashIranfar commented 1 year ago

Same issue. Don't know what to do

akasharidas commented 1 year ago

pip install --upgrade face-alignment==1.2.0 fixed it for me

RangerOnMars commented 1 year ago

I solved by installing face-alignment==1.3.4 It seems that _2D is removed or replaced in face-alignment>1.3.4? I created a PR for this #186

Pchdm commented 1 year ago

rewrite the code “self.model = face_alignment.FaceAlignment(face_alignment.LandmarksType._2D, flip_input=False)” to “self.model = face_alignment.FaceAlignment(face_alignment.LandmarksType.TWO_D, flip_input=False)” in DECA\decalib\datasets\detectors.py line 22.

AlbertBaichenDu commented 1 year ago

Thank you very much guys. Both solutions worked for me :-)