Skip to content
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

[Larix/feff fitting] plot each path not working under Windows (Larch 0.9.78) #515

Closed
nams-549 opened this issue May 24, 2024 · 8 comments
Closed
Milestone

Comments

@nams-549
Copy link

I updated larch and now larix isn't working. How do I resolve?

@newville
Copy link
Member

@nams-549 well, that probably depends on what the problem is.

What operating system are you using? What you did to install, update, or try to run the program? Were there any error messages?

One possibility (though maybe not the best one) would be to delete the installation folder completely and reinstall from the installer.

@nams-549
Copy link
Author

nams-549 commented May 26, 2024

Hii,
Thank you very much for replying. Sorry for not being clear on the previous message. I'm using windows 11. I faced the issue once I updated larch to the newer version. I updated running the code provided for "Update Larch". Then I deleted and reinstalled the software.

Now it works fine except the "plot each path " command in the feff fitting tab. The command doesn't seem to work .This feature was very helpful to track the contribution of each path and now I'm unable to use it.

image

And in the "feffit tab" I'm not able to plot nor change the plot type.
image

I didn't face any of these issues before I updated the software. Could you please suggest on how this can be resolved?

@maurov
Copy link
Member

maurov commented May 28, 2024

@newville I got a couple of reports from Windows users (with Larch 0.9.78) about an error plotting each path happening at this line:

for i, label in enumerate(paths.keys()):

I have only the following trace from a user:

NameError: name 'paths' is not defined. Did you mean: 'xpath'?
 Traceback (most recent call last):
   File "D:\Users\lacom\xraylarch\Lib\site-packages\larch\wxxas\feffit_panel.py", line 1171, in
onPlot
     self.plot_feffit_result(dataset_name, topwin=topwin, **opts)
   File "D:\Users\lacom\xraylarch\Lib\site-packages\larch\wxxas\feffit_panel.py", line 1237, in
plot_feffit_result
     for i, label in enumerate(paths.keys()):
                               ^^^^^
 NameError: name 'paths' is not defined. Did you mean: 'xpath'?

But I cannot reproduce it under Linux and latest master version.

Any further idea?

@maurov maurov changed the title Larix isn't working [Larix/feff fitting] plot each path not working under Windows (Larch 0.9.78) May 28, 2024
@newville
Copy link
Member

@maurov @nams-549 Yes, this is fixed in the master branch. A warning about that though: I have been playing with the ability to plot a sum of paths (and individual paths) without data. I believe this is now working, but I changed a lot of code in this area (in feffit_panel.py). I have tested it on some real examples but feel like I should probably test it more before all of that is released again.

@tuheihei
Copy link

tuheihei commented Jun 9, 2024

@maurov @nams-549 Yes, this is fixed in the master branch. A warning about that though: I have been playing with the ability to plot a sum of paths (and individual paths) without data. I believe this is now working, but I changed a lot of code in this area (in feffit_panel.py). I have tested it on some real examples but feel like I should probably test it more before all of that is released again.

@newville Hi, Newville, may I ask how to get this bug fixed? I installed Larch from conda-forge. Should I just wait for another release? Thanks

@newville
Copy link
Member

newville commented Jun 9, 2024

You can do a pip install of the nightly builds, as described in the documentation.

@josephzsombor
Copy link

I'm having this issue in Linux too. Just installed the most recent version.

@newville
Copy link
Member

@josephzsombor Yeah, sorry. This is fixed in the nightly build. See https://xraypy.github.io/xraylarch/installation.html#installing-the-development-version

@maurov maurov added this to the 0.9.80 milestone Jul 18, 2024
@maurov maurov closed this as completed Jul 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants