Closed aglavic closed 1 year ago
Am I being slow, or is there a unit difference in the thicknesses between the examples 1/3 and 4? The total thicknesses don't seem to add up for me without 1/3 being in nm and 4 being in A?
@jfkcooper What you are seeing is the newly added automatic unit conversion in combination with the globals-length_unit arguments. So example 1 is the default, which is nm, and 3+4 should be in angstrom.
But I noticed now a bug in the example 3, where the attribute is called length_units instead of length_unit, will correct that.
According to @jochenstahn it was decided to merge these developments. Will create another PR for the revision that will include the documentation and proper review.
Implement the ORSO header classes for the draft simple model language. The classes include the logic for resolving names and layers to be used easily by other programs.
The examples folder includes YAML from the website examples, a script that plots reflectivity and SLD from a given sample model, a conversion script showcasing the export of GenX models to the sample model and an estimator for measurement uncertainties based on a sample model string.
Some usage of the examples:
simple_model_example_1.yml
python resolve_and_plot_model.py simple_model_example_1.yml
simple_model_example_3.yml
python resolve_and_plot_model.py simple_model_example_3.yml
simple_model_example_4.yml
python sample2data.py "air | 5 (Co 31 | Fe 13) | Si"
python simple_model_from_genx.py ...\genx\genx\genx\examples\X-ray_Reflectivity.hgx simple_model_export_genx.yml
=> simple_model_export_genx.yml