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

quickgen can't simulate spectra above 500 #26

Closed
sbailey opened this issue Oct 10, 2015 · 1 comment
Closed

quickgen can't simulate spectra above 500 #26

sbailey opened this issue Oct 10, 2015 · 1 comment
Assignees
Labels
Milestone

Comments

@sbailey
Copy link
Contributor

sbailey commented Oct 10, 2015

Now that quickgen has been announced to the collaboration, bugs in it become high priority.

The options for simulating spectra above 499 appear to be broken. All of these should work:

quickgen --simspec {simspecfile...} --fibermap {fibermapfile} --nspec 500 --nstart 500 --spectrograph 1
quickgen --simspec {simspecfile...} --fibermap {fibermapfile} --nspec 500 --nstart 500
quickgen --simspec {simspecfile...} --fibermap {fibermapfile} --nspec 1000
quickgen --simspec {simspecfile...} --fibermap {fibermapfile} --nspec 5000

But they all fail with some version of:

Simulating spectrum 500,  object type=ELG
Traceback (most recent call last):
  File "/project/projectdirs/desi/software/edison/desisim/master/bin/quickgen", line 257, in <module>
    nobj[j,i,:waveMaxbin[channel]]=results.nobj[waveRange[channel],i]
IndexError: index 500 is out of bounds for axis 0 with size 500

As a result, quickgen can only simulate spectrograph 0 and not 1-9. Please fix.

@sbailey sbailey added the bug label Oct 10, 2015
@sbailey sbailey added this to the Argonne2015 milestone Oct 10, 2015
@gdhungana
Copy link
Contributor

@sbailey I just made a PR. The change is verified for all suggested options. Can even give any arbitrary values for nspec or nstart. like,

quickgen --simspec {simspecfile...} --fibermap {fibermapfile} --nspec 240 --nstart 950

@sbailey sbailey closed this as completed Oct 15, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants