Skip to content

Commit e3f34a6

Browse files
Simplify model path
Co-authored-by: Miles Cranmer <miles.cranmer@gmail.com>
1 parent 2981fa2 commit e3f34a6

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

scripts/huggingface/upload_model.py

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,7 @@
2020

2121
def retrive_model_path(model: torch.nn.Module) -> pathlib.Path:
2222
model_folder = inspect.getfile(model.__class__).split("/")[-2]
23-
model_path = (
24-
pathlib.Path(__file__)
25-
/ ".."
26-
/ ".."
27-
/ ".."
28-
/ "the_well"
29-
/ "benchmark"
30-
/ "models"
31-
/ model_folder
32-
).resolve()
23+
model_path = (CONFIG_DIR.parent / "models" / model_folder).resolve()
3324
return model_path
3425

3526

0 commit comments

Comments
 (0)