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

Mirror does not accept PreMLayer #12

Open
jureyherrera opened this issue Jun 23, 2023 · 1 comment
Open

Mirror does not accept PreMLayer #12

jureyherrera opened this issue Jun 23, 2023 · 1 comment

Comments

@jureyherrera
Copy link

There is an error when trying to use a file as reflectivity from PreMLayer.

image

In the other hand, using the option file 1D: (reflectivity vs energy) works very well.
As a suggestion:

  1. Since typically this file will be generated for example by XOPPY multilayer, the reflectivity can be saved as TAB separated (and can be read by shadow4), but always write a header, so it might be useful to skip the first row when loading:

    values = numpy.loadtxt(soe._file_refl)

  2. Another typical code to get the ML reflectivty is IMD for example, which uses ';' as comment, so it could be useful to define a comments='; ' to load directly files from it? (maybe is just too much)

  3. May be in the future would by nice just to accept the connection of XOPPY Multilayer?

Cheers, J

@srio
Copy link
Member

srio commented Jun 26, 2023

In fact, the PreMLayer is not accepted.

I wonder if it is convenient to create a separate widget for multilayers. The "shadow concept" of integrating multilayer reflectivity with mirrors is not very logic. We could create a PreMLayer preprocessor, somehow upgraded with a plot of the reflectivity, and maybe with a different (and easier) format and use it in the new mlayer widgets. Moreover, the widget would accept the external reflectivity files like in a mirror ( R(E), E(theta), R(E,theta)).

It will also be necessary to automaticcaly ling the xoppy mlayer (0r xoppy f1f2) to the mlayer (mirror).

Also, do not load the lines that contain comments in an automatic way.

Thanks for all these suggestions!

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

2 participants