Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

opening for 'reals' doesn't work, some validation fails... #25

Closed
ijiraq opened this issue Jun 19, 2013 · 2 comments · Fixed by #41
Closed

opening for 'reals' doesn't work, some validation fails... #25

ijiraq opened this issue Jun 19, 2013 · 2 comments · Fixed by #41
Labels

Comments

@ijiraq
Copy link
Member

ijiraq commented Jun 19, 2013

(Canopy 64bit) mach87:pymop jjk$ python mop.py
ERROR: AssertionError: Source doesn't have same number of observations (1) as in observations list (3). [pymop.io.astrom]
Traceback (most recent call last):
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/gui/taskselect.py", line 65, in _on_ok
self.setup_manager.set_task_info(self.browser.GetValue(), task)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/gui/taskselect.py", line 86, in set_task_info
self.app.set_task_info(working_directory, task)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/app.py", line 107, in set_task_info
self.launch(working_directory, task)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/app.py", line 117, in launch
self.start_task(working_directory, task)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/app.py", line 128, in start_task
self.task.start(working_directory)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/app.py", line 50, in start
workload = AstromWorkload(working_directory, workload_files)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/io/astrom.py", line 306, in init
self.astrom_data_list = [parser.parse(filename) for filename in self.full_paths]
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/io/astrom.py", line 183, in parse
sources = self._parse_source_data(filestr, observations)
File "/Users/jjk/Develop/MOP/src/ossos-pipeline/pymop/pymop/io/astrom.py", line 136, in _parse_source_data
len(source_obs), len(observations))
AssertionError: Source doesn't have same number of observations (1) as in observations list (3).

@drusk
Copy link
Contributor

drusk commented Jun 20, 2013

This indicates that one of the .reals.astrom files you were trying to process had a source with only a single X, Y, RA, DEC, etc reading (instead of 3). Can you check the directory you were processing for such a file?

@drusk
Copy link
Contributor

drusk commented Jun 20, 2013

This seems to be happening because the .reals.astrom headers are written out pre-maturely. If no sources are accepted, the resulting file should be empty. Right now it has the observation list at the top but no sources in the list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants