ChristopherMayes / lume-astra

Python wrapper for Astra (A Space Charge Tracking Algorithm, DESY) for eventual use in LUME https://christophermayes.github.io/lume-astra/
https://christophermayes.github.io/lume-astra/
Apache License 2.0
15 stars 9 forks source link

3D fieldmap import problem #31

Open vbnmgj opened 1 month ago

vbnmgj commented 1 month ago

Dear All,

I‘m new to Astra, and lume-astra helps me a lot. While I got an issue with the import of 3D fieldmap.

In the example given on the Astra official website, to import the 3D field of a cavity, you need to provide three files like DY_3D_TDS_ReIm.ex, DY_3D_TDS_ReIm.ey, and DY_3D_TDS_ReIm.ez, and use FILE_EFieLD(1) = 'DY_3D_TDS_ReIm' in astra.in to import the 3D field.

When I use the statement A.load_fieldmaps(), an error is reported

Loading fieldmap file DY_3D_TDS_ReIm
DY_3D_TDS_ReIm not found, searching:
FileNotFoundError: [Errno 2] No such file or directory: 'DY_3D_TDS_ReIm

I want to know how to correctly import 3D vector field?

Thanks for your help issue

ChristopherMayes commented 1 month ago

@vbnmgj could you zip up a complete example for me to look at?

vbnmgj commented 1 month ago

@vbnmgj could you zip up a complete example for me to look at?

Here are my files, 3D cavity example.zip DY_3D_TDS_ReIm... are download from https://www.desy.de/~mpyflo/EXAMPLES/Cavity_Example/ Thank you!