Skip to content

Commit

Permalink
Update validate.py
Browse files Browse the repository at this point in the history
  • Loading branch information
mzouink authored Feb 7, 2024
1 parent 8af4f90 commit 5c10f19
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions dacapo/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@ def validate_run(
evaluator.set_best(run.validation_scores)

for validation_dataset in run.datasplit.validate:
logger.warning("Validating on dataset %s", validation_dataset.name)
assert (
validation_dataset.gt is not None
), "We do not yet support validating on datasets without ground truth"
Expand All @@ -99,7 +98,7 @@ def validate_run(
f"{input_gt_array_identifier.container}/{input_gt_array_identifier.dataset}"
).exists()
):
logger.warning("Copying validation inputs!")
logger.info("Copying validation inputs!")
input_voxel_size = validation_dataset.raw.voxel_size
output_voxel_size = run.model.scale(input_voxel_size)
input_shape = run.model.eval_input_shape
Expand Down Expand Up @@ -137,20 +136,20 @@ def validate_run(
)
input_gt[output_roi] = validation_dataset.gt[output_roi]
else:
logger.warning("validation inputs already copied!")
logger.info("validation inputs already copied!")

prediction_array_identifier = array_store.validation_prediction_array(
run.name, iteration, validation_dataset
)
logger.warning("Predicting on dataset %s", validation_dataset.name)
logger.info("Predicting on dataset %s", validation_dataset.name)
predict(
run.model,
validation_dataset.raw,
prediction_array_identifier,
compute_context=compute_context,
output_roi=validation_dataset.gt.roi,
)
logger.warning("Predicted on dataset %s", validation_dataset.name)
logger.info("Predicted on dataset %s", validation_dataset.name)

post_processor.set_prediction(prediction_array_identifier)

Expand Down

0 comments on commit 5c10f19

Please sign in to comment.