[GSAS-II] Accessing image numpy array is gsas-ii scriptable
Toby, Brian H.
toby at anl.gov
Wed May 6 07:41:56 CDT 2020
Hi Leighanne,
Images are not stored in the .gpx file but need to be retrieved as they are needed. Routine _getCorrImage() does that. It is named with the leading underscore because I never intended it to be available in the API (I’m not sure why I did that, probably because it requires access to some internals that I did not expect users to sort out.) Contact me off-list and we can set up a time to talk so I can find out what you need and I can add something to the API.
Brian
On May 5, 2020, at 8:34 PM, Gallington, Leighanne C. via GSAS-II <gsas-ii at aps.anl.gov<mailto:gsas-ii at aps.anl.gov>> wrote:
Hi Bob and Brian,
I've been trying to incorporate GSAS-II scriptable into some python code I'm writing. I've figured out how to get the 2theta map, mask, and and I/pola maps out, but I was never able to figure out how to retrieve the numpy.array for each image. As a workaround, I read the images into my own code using the relevant bit of the tif reader code from GSAS-II (and I'm belatedly realizing as I write this email that I have could just modified Fill2thetaAziumthMap to output intensity in addition to intensity/pola), but it would be nice to be able to get that array by calling a function. Also, it would be nice if the arrays from that function were output as masked 2048*2048 arrays instead of 4+M*1 compressed arrays. Any thoughts?
Leighanne
--
Leighanne C. Gallington
Assistant Chemist
Advanced Photon Source (X-ray Science Division)
Argonne National Laboratory
Argonne, IL 60439
gallington at anl.gov<mailto:gallington at anl.gov>
_______________________________________________
GSAS-II mailing list
GSAS-II at aps.anl.gov<mailto:GSAS-II at aps.anl.gov>
https://mailman.aps.anl.gov/mailman/listinfo/gsas-ii
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.aps.anl.gov/pipermail/gsas-ii/attachments/20200506/72c40157/attachment.html>
More information about the GSAS-II
mailing list