xraypy / xraylarch

Larch: Applications and Python Library for Data Analysis of X-ray Absorption Spectroscopy (XAS, XANES, XAFS, EXAFS), X-ray Fluorescence (XRF) Spectroscopy and Imaging, and more.
https://xraypy.github.io/xraylarch
Other
133 stars 64 forks source link

Adding Feff input generator from general structure files #427

Closed Ameyanagi closed 1 year ago

Ameyanagi commented 1 year ago

Hi Matt,

I added a Feff input generator from the general structures we discussed on April 7th. Can you give me feedback on whether this direction looks ok or if I should implement it in a different manner? Please make a new branch if needed.

Summary

Other Comments

Ryuichi

newville commented 1 year ago

@Ameyanagi Wow, thanks! I'll try to give a more thorough review in the next couple of days.

newville commented 1 year ago

@Ameyanagi This looks very good to me. Would it be possible to include a small or medium-sized example structure file?

Ameyanagi commented 1 year ago

@newville Thanks, I will prepare some example structure files. Should I put it in /examples or in /tests?

newville commented 1 year ago

I would say to add it to the examples folder.

On Tue, Apr 11, 2023, 9:19 AM Ameyanagi @.***> wrote:

@newville https://github.com/newville Thanks, I will prepare some example structure files. Should I put it in /examples or in /tests?

— Reply to this email directly, view it on GitHub https://github.com/xraypy/xraylarch/pull/427#issuecomment-1503453510, or unsubscribe https://github.com/notifications/unsubscribe-auth/AACKI6ZTYY2LCBSCHIQJPZDXAVR6RANCNFSM6AAAAAAWY4HR74 . You are receiving this because you were mentioned.Message ID: @.***>

Ameyanagi commented 1 year ago

@newville I added several test files with different file formats (/structuredata/structure2feff). I used an organometallic cluster of mine as an example because it contains multiple metal centers, has crystalographic data, and is a molecule suitable for checking file format for molecules (such as XYZ and mol2).

Another issue is that I am unsure if the filename of poscar (VASP files) is usually saved as .poscar or POSCAR. The file name ".poscar" will work but "POSCAR" will not work on the current code, and this might need to be fixed if people prefer "POSCAR".

newville commented 1 year ago

@Ameyanagi Great, thanks! I think this will be very helpful, and merged it.

I have no opinion on POSCAR v poscar - it would be nice if both worked, but we can deal with that.

I think that @maurov mentioned that "CIF to FDMNES" was being worked on (or was working). We might want about refactoring/combining some of these codes to make more complete tools for "CIF or Structure Files" to "FEFF or FDMNES input", maybe both GUI and command-line / simple-ish functions.... But I'm not certain what that will look like.

Anyway, thanks!

Ameyanagi commented 1 year ago

@newville Thank you for the merge. As for the filename, the suffix will work regardless of been capital or not. My concern was that it would not work if the filename were "POSCAR" with no file extensions.

I agree with the refactoring of the tools and am willing to help with that in the future. Thanks.

maurov commented 1 year ago

@newville yes, we have a "CIF to FDMNES" code already available and I was planning to include it in Larch soon. The workflow is based on a Jupyter notebook.