-
Notifications
You must be signed in to change notification settings - Fork 68
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
Better handling non-XAS datatypes #451
Comments
Well, I guess we haven't had a lot of complaints about it ;) In fact, we don't even read chi(k) data from Athena Projects -- they aren't even shown as available when reading an Athena File. I might say: "not no", but it might be some real work, and it might not be my highest priority. I guess I might ask for suggestions on how to set such priorities?
OK. Maybe we should also aim to have this be a wider conversation? It's summer, and I have not tried to schedule a Larch Develepors meeting yet. Maybe this should be discussed there?
OK. Well, some things that are "globals" in a module are pretty specific to it. It is possible that "wxlib/columnframe.py" should be moved into "wxxas" -- it is pretty specific to XAS Viewer at this point.
I
I don't think I've heard that request before. Maybe we could just have a button that sets the edge_step to 1, or effectively
Another option would be a separate GUI for peak and general data fitting for non-XAS data. The fact that XAS Viewer can read non-XAS data has surprised several people ;)
OK.
Well, I guess I might ask whether we should deliberately target other spectroscopies or aim for a more general-purpose tool? FWIW, I will also be continuing to work on XRF fitting and XRF mapping software within Larch, but not XAS Viewer. Those GUIs need work too ;). I think going for a more general-purpose tool for curve fitting/peak fitting is a possibility too. That would basically be a data browser and LMFIT GUI that would be like XAS Viewer but not XAS-specific. So, more like a replacement for fityk than for Athena. But, maybe including the simple approaches to Linear-Combination and PCA in XAS Viewer for general-purpose data. My sense is that: This is better than trying to push "general purpose data" into XAS Viewer. I think the "build the actual GUI" is not very hard -- much of it would be XAS Viewer. I might consider a separate project from all of Larch, but I think that would be "undecided" at the moment. There are pros and cons... Do you have any thoughts on this? Like, imagine a variation of XAS Viewer that was really a replacement for Fityk -- would that be the right thing to do? That is all sort of a non-linear set of thoughts. Maybe a wider discussion is needed? |
Thanks for your comments. I agree that the overall topic should be discussed in a developers' meeting, probably after summer. In the meantime, few things that could be very helpful and should not affect that much the current code:
If you agree, I can take care doing this. Furthermore, the GUI should not reprocess the data each time passing from one group highlight to another, neither when simply doing a plot on current group or selected groups. Processing functions (e.g. PS:
If you know how to do this in wxPython, I would be interested in giving it a try. |
At the moment, it is only used by the column file reader and XAS Viewer. So maybe it should be in wxxas/config.py.
I think so. I'm not entirely clear about is how to "install that group" into XAS Viewer. XAS Viewer basically started as "XANES/XAS data viewer", so several of the panels, dialogs, and to some extent the Controller sort of assume there are "energy" and "norm" arrays, typically also called "xdat" and "ydat". For example, merging, LCF, and PCA only work on energy-arrayed data. If we support reading in chi(k) data from elsewhere, we will have to be explicit about whether these can work with chi(k) data or not. So, I'm not opposed, but I think this could actually be some effort. Are people asking for this? I have not heard of such a request. PS:
I think you can use Widget.Disable() or Widget.Enable(boolean_value) . I don't know if that works on the whole panel, but it might. Each TaskPanel has an onPanelExposed method that is run when that tab panel is brought forward. That currently gets the "current group" and fills in the form. You could try checking the "datatype" and Enable the panel if the datatype is supported for that panel. FWIW, I spent some time yesterday trying to figure out per-item coloring or font properties for the File List, and it does not look possible. |
Hello, I have a related request after trying to use XAS viewer to perform pre-edge peak analysis. I have a series of spectra that I import and would want to do the pre-edge fitting on that 'raw' data, but the only options are normalized, flattened and deconvolved. Thanks, |
@newville I have just realized that is not currently possible in xas_viewer to load a
k, chi
file and perform EXAFS analysis on it. I think this is a strong limitation and we should take action to solve it. Do you agree?We could take this occasion to extend and better handle non-XAS datatypes in xas_viewer and larch in general. Here some ideas (random order). Please, feel free to comment them:
DATATYPES
should be moved out of the GUI (larch.wxlib.columnframe
) and go into rootlarch
. By the way, I think this should be valid for all globals that are not strictly related to GUI.chi
datatype (or whatever naming) that when loaded will not allow to perform normalization and background removal. Ideally, the GUI should get all tabs disabled (visually grayed out, I do not know if this is possible with Wx) and leave only the EXAFS-related tabsxas_norm
datatype for already normalized XAS data -> the normalization panel should be disabledraw
datatype should not bring to the "XAS normalization" tab, but something more generic like a shell (I have in mind what is done in NexPy, all tabs should be disabled, apart peak fitting.So, the main question is: do we want to extend to other spectroscopy workflows rather than XAS? I think at least the Larch library should be able to know how to handle additional datatypes. Having the GUI also handling this would be great, but is much more work, I suppose.
The text was updated successfully, but these errors were encountered: