You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ok, I warn up front that this one is probably going to be very hard to track down.
pyromat version = bleeding edge
np version = 2.1.0
python version = 3.12.3
Steps to reproduce:
frompyromat.igtoolsimportIgtMixair=IgtMix('0.01289563 Ar + 0.00047711 CO2 + 0.75520558 N2 + 0.23142168 O2')
air.p(p=1, T=300)
Result: ValueError: output array is read-only
For what it's worth, it's being caused by the array of p being marked as read only, and you're trying to edit its value in place with np.multiply(). If you at an intermediate point within igtmix.p() re-assign the value with p = p.copy() it resolves the issue, but that doesn't seem ideal. I'm not up on the specifics of numpy data typing sufficiently to be able to trace this much further. If I have a chance to test in a different virtual environment with different numpy version, etc. I will do so.
The text was updated successfully, but these errors were encountered:
Ok I did a little messing around on a different computer, previous version of this message was in error because I had been using the wrong branch of the pyromat code.
in python 3.10.4
numpy versions 1.26.4 - code sample above fails
numpy version 2.1.0 - code sample above fails
numpy version 2.2.0 - code sample above fails
in python 3.12.8
numpy version 2.2.0 - code sample above fails
I'm not totally clear on whether this is something that's caused by pyromat or the underlying numpy compiled code. Searching for the error suggests that it has to do with when an array occupies a non-contiguous area in the memory. So it's possible that in one step along the way, the inplace calls are resulting in something affecting the memory.
Ok, I warn up front that this one is probably going to be very hard to track down.
pyromat version = bleeding edge
np version = 2.1.0
python version = 3.12.3
Steps to reproduce:
Result:
ValueError: output array is read-only
For what it's worth, it's being caused by the array of p being marked as read only, and you're trying to edit its value in place with np.multiply(). If you at an intermediate point within igtmix.p() re-assign the value with
p = p.copy()
it resolves the issue, but that doesn't seem ideal. I'm not up on the specifics of numpy data typing sufficiently to be able to trace this much further. If I have a chance to test in a different virtual environment with different numpy version, etc. I will do so.The text was updated successfully, but these errors were encountered: