Closed Tobias-Fischer closed 4 years ago
In addition, we now have diverging download structures, one in CMakeLists.txt
and the other in the download_models.py
.
I have toyed with the idea of executing download_models.py
once catkin_make
is run but the output of execute_process
isn't inlined with the output of catkin_make
making it look like the whole thing has frozen, when it hasn't....
If we do move towards download_models.py
as being our only way of downloading model files, we should think about removing the catkin_download
bit in CMakeLists.txt
Yes, I agree that we should remove the catkin_download
s altogether .. when I first did this there was only one model so it was fairly quick, but now it has exploded and we shouldn't do it during the build process anymore.
I thought about this again. I suggest the following:
download_models.py
into methods download_landmark_models()
, download_gaze_tensorflow_models()
, download_gaze_pytorch_models()
and download_blink_models()
. The __main__
of download_models.py
then simply calls all of these methods.estimate_gaze.py
and estimate_gaze_standalone.py
, depending on the backend chosen, either call download_gaze_pytorch_models()
or download_gaze_tensorflow_models()
.request_if_not_exist
after downloading the model and not every time to avoid introducing start-up latencies.What do you think @ahmed-alhindawi? If you're happy with the suggestion I'll go ahead with it.
Sounds great!
Allow running estimate_gaze.py etc without having to run download_models.py; in that case, download the models at runtime.