Repository navigation
One failing io.fits test on Numpy 1.10.1 - #4266
Conversation
|
I believe that Numpy 1.10.1 also forces specutils to fail And, it does affect me so I suspect this is a significant issue. |
|
We'll see. I'm not entirely sure it's a bug in Numpy--I forgot a lot of stuff over vacation. |
|
This is continuing to cause problems, especially among those who And I expect that specutils is still failing its tests. |
|
@profxj What specifically is causing problems? This specific issue is about one test that was failing, but is there some other failure you can point to? Astropy v1.0.6 should have resolved all common issues with Numpy 1.10. |
|
@profxj In other words, please post some specific code that's failing. |
|
I see now that it is a bug in specutils (I think) via numpy Here is the trouble in specutils: as evidence by this simple snippet. |
|
@profxj That looks like an issue to raise in specutils. |
…not sure how this passed on earlier Numpy versions either...)
275845f to
74349eb
Compare
|
Had to rebase. |
|
@embray - don't feel like a FITS expert by any means, but I think this all looks good. |
|
The issue here was that when writing a table out to a FITS file, depending on where the table data came from in the first place any number of the columns may have to be byte-swapped individually. This also means assigning a new dtype to the data with the relevant columns byte-swapped. Unfortunately, teasing apart a multi-field dtype and reassembling it correctly can be something of a pain, since there are a few applications in FITS where fields need to be able to have arbitrary offsets, and Numpy makes it less easy than it should be to create a new multi-field dtype from an existing one with the correct offsets maintained as well. The code fixed in this PR was not careful to preserve the offsets in a case where they mattered. Numpy < 1.10 didn't care, but Numpy 1.10 was somehow catching the inconsistency (I forget exactly what the error was though...) |
One failing io.fits test on Numpy 1.10.1
|
@embray - OK, thanks for the explanation. Nice to be fully OK with 1.10 now! (though one needs 1.10.2 to avoid some of the numpy slowdowns). |
One failing io.fits test on Numpy 1.10.1
Not sure how, but I completely missed this somehow when I was finishing up testing for v1.0.6. I don't have time to fix it right now so I've marked the test as xfail on Numpy 1.10 for now. It's an obscure case that probably shouldn't affect any users.
See 06a53a1