zhengyuf / STED-gaze

Code for paper 'Self-learning Transformations for Improving Gaze and Head Redirection'
GNU General Public License v3.0
89 stars 23 forks source link

PerceptualSimilarity #5

Closed LeArmadillo closed 3 years ago

LeArmadillo commented 3 years ago

Hi Zhengyuf,

The train_st_ed.py script is looking for a folder PerceptualSimilarity, can you provide the source for this?

STED-gaze-master# python train_st_ed.py config/eval.json Traceback (most recent call last): File "train_st_ed.py", line 20, in from models import STED File "/translation/STED-gaze-master/models/init.py", line 2, in from .st_ed import STED File "/translation/STED-gaze-master/models/st_ed.py", line 27, in from .PerceptualSimilarity.lpips_models import PerceptualLoss ModuleNotFoundError: No module named 'models.PerceptualSimilarity'

LeArmadillo commented 3 years ago

Also seem to be missing DisModel():

Traceback (most recent call last): File "train_st_ed.py", line 119, in network = STED().to(device) File "/translation/STED-gaze-master/models/st_ed.py", line 80, in init self.lpips = PerceptualLoss(model='net-lin', net='alex').to("cuda") File "/translation/STED-gaze-master/models/st_ed.py", line 43, in init self.model = dist_model.DistModel() NameError: name 'dist_model' is not defined

zhengyuf commented 3 years ago

hey, the perceptual similarity model is from this repo: https://github.com/richzhang/PerceptualSimilarity I've updated my code to work with theirs :) Just pull the updates and install lpips with pip, and it should be fine now.

zhengyuf commented 3 years ago

as for the problem with DisModel, i don't think i used that, and i cannot find it on the 43rd line of st_ed.py.

LeArmadillo commented 3 years ago

Thanks! That fixed it