NeoGeographyToolkit / StereoPipeline

The NASA Ames Stereo Pipeline is a suite of automated geodesy & stereogrammetry tools designed for processing planetary imagery captured from orbiting and landed robotic explorers on other planets.
Apache License 2.0
478 stars 168 forks source link

parse_match_file.py fails with some input text files #349

Closed PicoJr closed 2 years ago

PicoJr commented 2 years ago

Describe the bug parse_match_file.py fails with the following input:

test.bin.txt

1 2
42.0 43.0 42 43 52.0 53.0 54.0 3 62 63 2 44.0 44.0
42.0 43.0 42 43 52.0 53.0 54.0 3 62 63 2 44.0 44.0
42.0 43.0 42 43 52.0 53.0 54.0 3 62 63 2 44.0 44.0
python parse_match_file.py -rev test.bin.txt test.bin.out

output:

Reading: test.bin.txt
Writing: test.bin.out
Traceback (most recent call last):
  File "/home/redacted/clones/StereoPipeline/src/asp/Tools/parse_match_file.py", line 199, in <module>
    write_match_file(args.outfile, im1_ipb, im2_ipb)
  File "/home/redacted/clones/StereoPipeline/src/asp/Tools/parse_match_file.py", line 121, in write_match_file
    size1 = len(im1_ip)
TypeError: len() of unsized object

Expected behavior parse_match_file.py should not fail with the given input file.

Your Environment (please complete the following information):