emolter / pylanetary

data processing and modeling tools for ring, moon, and planet observations
GNU General Public License v3.0
8 stars 6 forks source link

Using the nav tutorial w/ IRTF data #38

Closed dahlek closed 10 months ago

dahlek commented 1 year ago

Hey Ned, I'm having trouble getting nav.colocate to work with some of my IRTF images. I think I've correctly assigned 'model' and 'data', but when I run this line: dx, dy, dxerr, dyerr = nav.colocate(mode='disk', tb = flux, a = a, beam = fwhm_keck, err=rms_noise) I'm getting an error that the model and data images aren't the same shape. I tried adding a definition of the size of the image using the optional shape argument in ModelBody(), but that didn't seem to work. What am I missing here? I can attach a screenshot of the error if that's helpful.

emolter commented 1 year ago

Hi Emma, sorry you're having that issue. Can you send me the full error message?

emolter commented 1 year ago

My coworker Damya is having the same issue with some Keck data, and sent me a test fits file and full error log. I'm planning to work on this tomorrow and perhaps the weekend, so stay tuned for a resolution. Marking this as "bug" for now

dahlek commented 1 year ago

I think I've found another bug or two w/ nav while working on this spectral extraction stuff, I'll compile a list and make sure you can reproduce them once I've got some time (hopefully soon???)

emolter commented 1 year ago

that would be great! Thanks for being the first alpha tester :)

dahlek commented 1 year ago

A quick note too if I haven't said it elsewhere: if we can make maps of solar emission/zenith angle and azimuth angle with nav that would simplify my code a lot, currently I'm still using one of pat's codes to find those values (unless I'm missing that nav can do that already?)

emolter commented 1 year ago

Nav can already compute the normal vector toward the sun from each point on the planet with the function sun_normal() but it is completely untested. The solar emission and zenith angles are relatively easy to compute from this quantity. I agree this would be very useful to write and test; maybe it deserves its own issue?

emolter commented 1 year ago

@dahlek the most recent commit to the active-dev branch should have fixed the shape issue you were having. When you get a chance, could you please re-install pylanetary from the active-dev branch, i.e., pip install git+https://github.com/emolter/pylanetary.git@active-dev and then retry on your IRTF image?

also, would you like to meet via Zoom sometime and update me on your experience trying to use the software?

emolter commented 1 year ago

one more thing - this might require pip install --force-reinstall, at least it did for Damya.

dahlek commented 10 months ago

Tested this with the newest version and problem solved!

emolter commented 10 months ago

glad to hear it!