Skip to content

Attribute Error occurs 'Ground truth (GT) generation' step #45

@sktm502

Description

@sktm502

Hi.
I encounter 'AttributeError: 'NoneType' object has no attribute 'shape'' error when excute Ground truth (GT) generation step.(I`m using python 3.12)
I commanded as below.

python -m deeplsd.scripts.homography_adaptation_df C:\DeepLSD2\DeepLSD\dataset\img_list.txt C:\DeepLSD2\DeepLSD\GT_output --num_H 100 --n_jobs 5

It seems some calculation did incorrectly. I think that install dependencies corretly, but I'm not confident.

whole output is as below

(deeplsd2) c:\DeepLSD2\DeepLSD>python -m deeplsd.scripts.homography_adaptation_df C:\DeepLSD2\DeepLSD\dataset\img_list.txt C:\DeepLSD2\DeepLSD\GT_output --num_H 100 --n_jobs -1
100%|█████████████████████████████████████████████████████████████████████████████████| 16/16 [00:00<00:00, 185.53it/s]
[ WARN:0@6.295] global loadsave.cpp:241 cv::findDecoder imread_('C:/DeepLSD/dataset/v1.1/test/00031597.jpg'): can't open/read file: check file path/integrity
joblib.externals.loky.process_executor._RemoteTraceback:
"""
Traceback (most recent call last):
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib_utils.py", line 72, in call
return self.func(**kwargs)
^^^^^^^^^^^^^^^^^^^
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 598, in call
return [func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "c:\DeepLSD2\DeepLSD\deeplsd\scripts\homography_adaptation_df.py", line 135, in process_image
df, angle, closest, bg_mask = ha_df(img, num=num_H)
^^^^^^^^^^^^^^^^^^^^^
File "c:\DeepLSD2\DeepLSD\deeplsd\scripts\homography_adaptation_df.py", line 46, in ha_df
h, w = img.shape[:2]
^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'shape'
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "", line 198, in _run_module_as_main
File "", line 88, in _run_code
File "c:\DeepLSD2\DeepLSD\deeplsd\scripts\homography_adaptation_df.py", line 176, in
export_ha(args.images_list, args.output_folder, args.num_H,
File "c:\DeepLSD2\DeepLSD\deeplsd\scripts\homography_adaptation_df.py", line 158, in export_ha
Parallel(n_jobs=n_jobs, backend='multiprocessing')(delayed(process_image)(
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 2007, in call
return output if self.return_generator else list(output)
^^^^^^^^^^^^
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 1650, in _get_outputs
yield from self._retrieve()
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 1754, in _retrieve
self._raise_error_fast()
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 1789, in _raise_error_fast
error_job.get_result(self.timeout)
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 745, in get_result
return self._return_or_raise()
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\jonghak\anaconda3\envs\deeplsd2\Lib\site-packages\joblib\parallel.py", line 763, in _return_or_raise
raise self._result
AttributeError: 'NoneType' object has no attribute 'shape'

Thank you for your coorperation in advance

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions