wizzseen commited on
Commit
61990d5
·
verified ·
1 Parent(s): 6b93ef6

Update TryYours-Virtual-Try-On/posenet/converter/tfjs2pytorch.py

Browse files
TryYours-Virtual-Try-On/posenet/converter/tfjs2pytorch.py CHANGED
@@ -96,9 +96,9 @@ def convert(model_id, model_dir, output_stride=16, image_size=513, check=True):
96
  checkpoint_path = os.path.join(model_dir, checkpoint_name) + '.pth'
97
  torch.save(m.state_dict(), checkpoint_path)
98
 
99
- if check and os.path.exists("./images/tennis_in_crowd.jpg"):
100
  # Result
101
- input_image = _read_imgfile("./images/tennis_in_crowd.jpg", width, height)
102
  input_image = np.array(input_image, dtype=np.float32)
103
  input_image = input_image.reshape(1, 3, height, width)
104
  input_image = torch.Tensor(input_image)
 
96
  checkpoint_path = os.path.join(model_dir, checkpoint_name) + '.pth'
97
  torch.save(m.state_dict(), checkpoint_path)
98
 
99
+ if check and os.path.exists("TryYours-Virtual-Try-On/posenet/converter/images/tennis_in_crowd.jpg"):
100
  # Result
101
+ input_image = _read_imgfile("TryYours-Virtual-Try-On/posenet/converter/images/tennis_in_crowd.jpg", width, height)
102
  input_image = np.array(input_image, dtype=np.float32)
103
  input_image = input_image.reshape(1, 3, height, width)
104
  input_image = torch.Tensor(input_image)