Tobias-Fischer / rt_gene

RT-GENE: Real-Time Eye Gaze and Blink Estimation in Natural Environments
http://www.imperial.ac.uk/personal-robotics
Other
368 stars 68 forks source link

Generating Eye Patches Issue and Question #84

Closed GrantZheng86 closed 3 years ago

GrantZheng86 commented 3 years ago

Hi there,

Thanks for this great project!

Here's the Issue: As I was trying to train the CNN following the steps of README from the "_rt_gene/rt_gene_modeltraining/" page. I encountered an error

"GenerateEyePatchesRTGENEDataset.py" prompted an error saying that

"'TrackedSubject' object has no attribute 'transformed_eye_landmarks'"

I double-checked the "_trackergeneric.py" file, and there was indeed no "_transformed_eyelandmarks" object in the "TrackedSubject' class (but there's a local variable with the same name in "get_eye_image_from_landmarks" function). When running this "GenerateEyePatchesRTGENEDataset.py" file, I copied the face images from nonglass folder founded here https://zenodo.org/record/2529036#.X8clOllKg1g (I think this should contain the right images). Could there a bug in the generating eye patch code?

Here's the question: As I was going through the dataset, I was also wondering if the "GenerateEyePatchesRTGENEDataset.py" will produce the same images as in the "_s0XXglasses/inpainted/left" (and also /right)? Also, will the next step in the README:

Compile the left_new and right_new patches along the labels into a h5 file using GenerateRTGENEH5Dataset.py, optionally augment the patches here to make it as similar to prepare_dataset.m from the tensorflow preparation stage.

output the same file as the "_Labelcombined.txt" in the folder "_s0XXglasses/" ?

Thanks in advance for helping out!

Tobias-Fischer commented 3 years ago

Hi there,

Many thanks for reporting this issue! The error stems from some recent refactoring and we must not have checked the GenerateEyePatches file. I just fixed your problem in the master branch (https://github.com/Tobias-Fischer/rt_gene/commit/afba793617a78a5cfc346d523907c9c972a2c4ae), please pull the latest code and you should be good to go.

Regarding your question: The images won't be exactly the same. The images that are contained in the dataset are extracted using a much older version of RT-GENE, so there will be some small differences. I'm not sure whether it creates a Label_combined.txt - @ahmed-alhindawi any hints?