Skip to content

input_data_dict should NOT be required to run CellmapsImageDownloader #2

@coleslaw481

Description

@coleslaw481
  • cellmaps_imagedownloader version: 0.1.0a4
  • Python version: 3.8
  • Operating System: mac

Description

Attempting to invoke CellmapsImageDownloader run() method fails because it expects samples and unique keys with values in input_data_dict parameter in constructor

What I Did

imagegen = ImageGeneNodeAttributeGenerator(
            unique_list=ImageGeneNodeAttributeGenerator.get_unique_list_from_csvfile(<unique APMS csv file>),
            samples_list=ImageGeneNodeAttributeGenerator.get_samples_from_csvfile(<samples APMS csv file>))

CellmapsImageDownloader(outdir='/tmp/foo,
                                       imagedownloader=FakeImageDownloader(),
                                       imagegen=imagegen,
                                       provenance=self._provenance).run()


Above outputs:

2023-05-19 15:34:27,637 ERROR 950ms cellmaps_pipelinecmd.py::main():157 Caught exception: 'NoneType' object is not subscriptable
Traceback (most recent call last):
  File "/Users/churas/anaconda3/envs/python382/bin/cellmaps_pipelinecmd.py", line 153, in main
    return CellmapsPipeline(outdir=theargs.outdir,
  File "/Users/churas/anaconda3/envs/python382/lib/python3.8/site-packages/cellmaps_pipeline/runner.py", line 142, in run
    exit_status = self._runner.run()
  File "/Users/churas/anaconda3/envs/python382/lib/python3.8/site-packages/cellmaps_pipeline/runner.py", line 73, in run
    if self._download_images() != 0:
  File "/Users/churas/anaconda3/envs/python382/lib/python3.8/site-packages/cellmaps_pipeline/runner.py", line 93, in _download_images
    return CellmapsImageDownloader(outdir=self._image_dir,
  File "/Users/churas/anaconda3/envs/python382/lib/python3.8/site-packages/cellmaps_imagedownloader/runner.py", line 606, in run
    self._register_input_datasets()
  File "/Users/churas/anaconda3/envs/python382/lib/python3.8/site-packages/cellmaps_imagedownloader/runner.py", line 403, in _register_input_datasets
    source_file=self._input_data_dict[CellmapsImageDownloader.SAMPLES_FILEKEY],
TypeError: 'NoneType' object is not subscriptable

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions