Skip to content

Commit 43c4e82

Browse files
committed
upd
1 parent dc2d820 commit 43c4e82

File tree

4 files changed

+16
-3
lines changed

4 files changed

+16
-3
lines changed

ml-runs/0/meta.yaml

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
artifact_location: file:///Users/alex/Projects/open-metric-learning/ml-runs/0
2+
creation_time: 1712785684615
3+
experiment_id: '0'
4+
last_update_time: 1712785684615
5+
lifecycle_stage: active
6+
name: Default

oml/registry/transforms.py

+1
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ def save_transforms_as_files(cfg: TCfg) -> List[Tuple[str, str]]:
108108
keys_files.append((key, transforms_file))
109109
except Exception:
110110
print(f"We are not able to interpret {key} as albumentations transforms and log them as a file.")
111+
print(keys_files, "zzzz")
111112
return keys_files
112113

113114

tests/test_oml/test_functional/test_metrics/test_retrieval_metrics.py

+3
Original file line numberDiff line numberDiff line change
@@ -314,3 +314,6 @@ def test_calc_fnmr_at_fmr_check_params(fmr_vals: Tuple[int, ...]) -> None:
314314
pos_dist = torch.zeros(10)
315315
neg_dist = torch.ones(10)
316316
calc_fnmr_at_fmr(pos_dist, neg_dist, fmr_vals)
317+
318+
319+
# todo 525: add a test for a new metric signature with clipped matrix of predictions

tests/test_oml/test_registry/test_registry.py

+6-3
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,10 @@ def test_saving_transforms_as_files() -> None:
142142
cfg = yaml.safe_load(cfg)
143143
save_transforms_as_files(cfg)
144144

145-
assert Path("transforms_train.yaml").exists()
146-
assert not Path("transforms_val.yaml").exists()
145+
assert Path("transforms_train.yaml").exists() or Path(".hydra/transforms_train.yaml").exists()
146+
assert (not Path("transforms_val.yaml").exists()) and (not Path("transforms_val.yaml").exists())
147147

148-
Path("transforms_train.yaml").unlink()
148+
if Path("transforms_train.yaml").exists():
149+
Path("transforms_train.yaml").unlink()
150+
else:
151+
Path(".hydra/transforms_train.yaml").unlink()

0 commit comments

Comments
 (0)