MONAI icon indicating copy to clipboard operation
MONAI copied to clipboard

Design Pre-Processing Pipeline to be Finalize

Open pdogra89 opened this issue 6 years ago • 4 comments

pdogra89 avatar Jan 24 '20 16:01 pdogra89

I'm progressing a design doc for the preprocessing pipeline in the wiki. Things have been hectic this week but we should book a meeting slot for Monday afternoon to have a discussion and for others to contribute their ideas. We could aim for 9am Pacific Time, 5pm UK time if everyone is free.

(use case of loading/padding/cropping windows: https://github.com/MIC-DKFZ/batchgenerators/blob/master/batchgenerators/examples/brats2017/brats2017_dataloader_2D.py)

atbenmurray avatar Jan 30 '20 13:01 atbenmurray

Conclusions of meeting:

  1. All transforms should be implemented as vanilla python functions
  2. A Compose function will be implemented that composes functions assuming a single argument and single return value (both of which can be dictionaries)
  3. A generic wrapper will be implemented that wraps vanilla transforms so that they can be Composed. The wrapper takes a dictionary and mappings between the dictionary entries and the functions. This will be added to a WIP PR on a branch created for this purpose
    1. We will find challenging use cases that test the genericity of the wrapper with the goal that the wrapper remains completely generic
  4. We will write an alternative to compose that allows users to create non-linear combinations of transforms and avoid the use of wrappers. The goal is to allow torchvision style compose but prefer the avoidance of compose

atbenmurray avatar Feb 04 '20 16:02 atbenmurray

Following a successful discussion, the following issues for implementing specific parts of this work have been split up into individual work items that can be independently PR-ed and closed

  • #58 for the adaptor functionality / docs
  • #59 for the Compose functionality / docs
  • #61 for the wiki updates

atbenmurray avatar Feb 07 '20 15:02 atbenmurray

Everyone to import transforms to this and stress test the adapt capabilities.

pdogra89 avatar Feb 07 '20 16:02 pdogra89