Skip to content

Commit

Permalink
Add _v2 suffix to model file name
Browse files Browse the repository at this point in the history
  • Loading branch information
iimog committed Jun 8, 2022
1 parent 90f7f59 commit b6780b3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions hubconf.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
# b0_transversal_5_5 is the name of entrypoint
def b0_transversal_5_5(**kwargs):
""" # This docstring shows up in hub.help()
Initial model trained on 138 transversal images via transfer learning on the base model chfc-cmi/cmr-seg-tl : cmr_seg_base
Initial model trained on 138 transversal images via transfer learning on the base model chfc-cmi/cmr-seg-tl : cmr_seg_base with fastai v2
"""
# Call the model, load pretrained weights
url = "https://github.com/chfc-cmi/transversal-cmr-seg/releases/download/0.2.0/b0_transversal_5_5.pth"
dst = torch.hub.get_dir() + '/chfc-cmi_transversal-cmr-seg_master/' + 'b0_transversal_5_5.pth'
url = "https://github.com/chfc-cmi/transversal-cmr-seg/releases/download/0.2.0/b0_transversal_5_5_v2.pth"
dst = torch.hub.get_dir() + '/chfc-cmi_transversal-cmr-seg_master/' + 'b0_transversal_5_5_v2.pth'
if not os.path.isfile(dst):
torch.hub.download_url_to_file(url,dst,progress=True)
model = fastai.learner.load_learner(path=tempfile.gettempdir(),file=dst,tfm_y=False)
Expand Down

0 comments on commit b6780b3

Please sign in to comment.