question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Improve the predict output file options

See original GitHub issue

Issue description

Currently, predict/deepreg_predict saves input images/labels for different label pairs, with both png and nifti file formats. This leads to sizable written files.

1 - Add options that can turn off the following for space-saving/speed:

  • Save input images/labels (useful for debugging or research);
  • Save png files
  • Save nifti files (is this useful to be able to turn off?)

2 - Avoid saving the same input files multiple times.

Type of Issue

  • New feature request
  • Documentation update
  • Test request

What’s the expected result?

What’s the actual result?

Additional details / screenshot

-

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
NMontanaBrowncommented, Aug 6, 2020

Also, I was reviewing this for the edu challenge and at this line we call:

# predict
 # (batch, f_dim1, f_dim2, f_dim3)
        pred_fixed_label = outputs_dict.get("pred_fixed_label", None)
        pred_fixed_image = (
            layer_util.resample(vol=moving_image, loc=fixed_grid_ref + ddf)
            if ddf is not None
            else None
        )

Which I found quite confusing: the warped image is called pred_fixed_image, which I associated to the fixed image. I would suggest renaming this and the save file for clarity to warped_moving_image, or something along the lines?

@YipengHu @mathpluscode @s-sd

1reaction
mathpluscodecommented, Aug 2, 2020

so ideally, the output should be like following (this has been discussed before lol)

  • one folder per image pair (not related to label)
    • input images
    • one subfolder per label
      • input label
      • outputs

then for the following items we can choose to save or not

  • input images/labels, default false
  • png, default false
  • nifti, default true

@YipengHu what do you think?

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Make Predictions with Keras - Machine Learning Mastery
We can predict the class for new data instances using our finalized classification model in Keras using the predict_classes() function. Note ...
Read more >
Using machine learning to predict what file you need next
As we laid out in our blog post introducing DBXi, Dropbox is building features to help users stay focused on what matters.
Read more >
How to use a model to do predictions with Keras - ActiveState
Specifies what layers the model contains, and how they are connected. Weights. Input parameters that influence output in a Keras model.
Read more >
Prediction output options: DataRobot docs
Learn how to program your batch prediction job's output. You can use local file streaming, S3 scoring, an AI Catalog dataset, JDBC, Snowflake,...
Read more >
Reading the Batch Prediction Output Files - Amazon Machine ...
Locate the batch prediction manifest file. · Read the manifest file to determine the locations of output files. · Retrieve the output files...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found