centreborelli / s2p

Satellite Stereo Pipeline
GNU Affero General Public License v3.0
208 stars 67 forks source link

Error is caused when using test data #105

Closed JaeWangL closed 2 years ago

JaeWangL commented 3 years ago

I just typed "s2p tests/data/input_pair/config.json" in terminal But below error is showed How can I fix this?

tile size: 350 350
total number of tiles: 4 (2 x 2)

discarding masked tiles...
multiprocessing.pool.RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/multiprocessing/pool.py", line 125, in worker
    result = (True, func(*args, **kwds))
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/site-packages/s2p/initialization.py", line 296, in is_this_tile_useful
    rpc = cfg['images'][0]['rpcm']
KeyError: 'images'
"""

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

Traceback (most recent call last):
  File "/Users/jaewanglee/opt/anaconda3/bin/s2p", line 8, in <module>
    sys.exit(main())
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/site-packages/s2p/cli.py", line 22, in main
    s2p.main(user_cfg)
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/site-packages/s2p/__init__.py", line 534, in main
    tiles = initialization.tiles_full_info(tw, th, tiles_txt, create_masks=True)
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/site-packages/s2p/initialization.py", line 346, in tiles_full_info
    tiles_usefulnesses = parallel.launch_calls(is_this_tile_useful,
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/site-packages/s2p/parallel.py", line 102, in launch_calls
    outputs.append(r.get(timeout))
  File "/Users/jaewanglee/opt/anaconda3/lib/python3.8/multiprocessing/pool.py", line 771, in get
    raise self._value
KeyError: 'images'
JaeWangL commented 3 years ago

In "is_this_tile_useful" in s2p/initialization.py I printed config for checking my settings like following

print(cfg['images'])
rpc = cfg['images'][0]['rpcm']

But cfg doens't contains my values. So, rpc has no value Is it normal??

In Addition, in "tiles_full_info", cfg has my own values

JaeWangL commented 3 years ago

My environment is Python 3.8 with anaconda3 on MacOS

diego-gris commented 2 years ago

@JaeWangL, did you figure out this issue?