rajatsingh0702 commited on
Commit
cd097dc
·
1 Parent(s): b09c365

Update mymodels.py

Browse files
Files changed (1) hide show
  1. mymodels.py +2 -2
mymodels.py CHANGED
@@ -5,7 +5,7 @@ import cv2
5
  import numpy as np
6
 
7
  __all__ = [
8
- 'color_cluster','Color2Sketch', 'Sketch2Color', 'Discriminator',
9
  ]
10
 
11
 
@@ -259,7 +259,7 @@ class Color2Sketch(nn.Module):
259
  if pretrained:
260
  print('Loading pretrained {0} model...'.format('Color2Sketch'), end=' ')
261
  checkpoint = torch.load('color2edge.pth')
262
- self.load_state_dict(checkpoint['netG'], strict=True)
263
  print("Done!")
264
  else:
265
  self.apply(weights_init)
 
5
  import numpy as np
6
 
7
  __all__ = [
8
+ 'color_cluster', 'Color2Sketch', 'Sketch2Color', 'Discriminator',
9
  ]
10
 
11
 
 
259
  if pretrained:
260
  print('Loading pretrained {0} model...'.format('Color2Sketch'), end=' ')
261
  checkpoint = torch.load('color2edge.pth')
262
+ self.load_state_dict(checkpoint['netG'], strict=False)
263
  print("Done!")
264
  else:
265
  self.apply(weights_init)