While using facexlib in Real-ESRGAN for face enhance warnings occurs about torchvision versions #687
Ishfak00
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
1.1 While using facexlib in Real-ESRGAN for face enhance warnings occurs about torchvision versionss as below:
########################################################################################
**/root/miniconda3/lib/python3.11/site-packages/torchvision/models/_utils.py:208: UserWarning: The parameter 'pretrained' is deprecated since 0.13 and may be
removed in the future, please use 'weights' instead.
warnings.warn(
/root/miniconda3/lib/python3.11/site-packages/torchvision/models/_utils.py:223: UserWarning: Arguments other than a weight enum or
Nonefor 'weights' aredeprecated since 0.13 and may be removed in the future. The current behavior is equivalent to passing
weights=None.warnings.warn(msg)**_
########################################################################################
Though there is working code examples are given in pytorch.org website, it is quiet puzzling where to set these codes.
After searching and some tryouts I have changed file in here:
/root/miniconda3/lib/python3.11/site-packages/facexlib/detection/retinaface.py
and my new codes were as below:
Of course, commenting out old three line of codes. And it worked fine with no error or warning! 👍
You should have give a thought to change the facexlib in here as soon pytorch will deprecate the old method.
https://pypi.org/project/facexlib/#description
All reactions