Molass Library Reference#
Molass Library is a rewrite of MOLASS, an analytical tool for SEC-SAXS experiment data currently hosted at Photon Factory or SPring-8, Japan.
This document describes each function of the library.
For details, see also:
Essence: https://nshimizu0721.github.io/molass-essence for theory,
Tutorial: https://nshimizu0721.github.io/molass-tutorial for how to use,
Technical Report: https://freesemt.github.io/molass-technical/ for technical details,
Legacy Reference: https://freesemt.github.io/molass-legacy/ for the GUI application version.
To join the community, see also:
Handbook: https://nshimizu0721.github.io/molass-develop for maintenance.
Module Functions#
- to_int_tuple(version_string)#
Convert a version string to a tuple of integers.
- Parameters:
version_string (str) – A version string in the format ‘major.minor.patch’.
- Returns:
tuple
- Return type:
A tuple of integers representing the version.
- class Version(version_string)#
Bases:
object
- get_version(toml_only=False)#
Retrieve the version of the package from pyproject.toml or importlib.metadata.
This function prioritizes reading the version from pyproject.toml to ensure that the local repository version is used during development or testing. If pyproject.toml is not found, it falls back to using importlib.metadata to retrieve the version of the installed package.
- Parameters:
toml_only (bool, optional) –
If True, the function strictly reads the version from pyproject.toml. This is crucial to avoid confusion about the version being used, which can lead to significant time loss during testing. (confusion about the local repository versus the installed).
If False, the function attempts to read the version from pyproject.toml first. If pyproject.toml does not exist, which means you are using the installed package, it falls back to using importlib.metadata to retrieve this version.
- Returns:
Version – This value is returned as a Version object, which provides comparison operators (as tuple of integers) for version strings.
- Return type:
The version of the package.
- Raises:
AssertionError: – If toml_only is True but pyproject.toml is not found. This ensures that the function behaves predictably in cases where the local repository is not available.
This docstring was improved in collaboration with GitHub Copilot. –
Submodules#
- Baseline
- Bridge
- CurveModels
- CurveModels.Scattering
- CurveModels.Scattering.FormFactors
- DataObjects
- Submodules
- DataObjects.Curve
- DataObjects.DenssInputData
- DataObjects.SecSaxsData
SecSaxsData
SecSaxsData.plot_3d()
SecSaxsData.plot_compact()
SecSaxsData.make_trimming()
SecSaxsData.plot_trimming()
SecSaxsData.copy()
SecSaxsData.trimmed_copy()
SecSaxsData.set_baseline_method()
SecSaxsData.get_baseline_method()
SecSaxsData.corrected_copy()
SecSaxsData.estimate_mapping()
SecSaxsData.get_mapping()
SecSaxsData.get_concfactor()
SecSaxsData.quick_decomposition()
SecSaxsData.inspect_ip_effect()
SecSaxsData.get_uv_device_id()
SecSaxsData.get_beamline_name()
SecSaxsData.export()
- DataObjects.SsMatrixData
- DataObjects.UvData
- DataObjects.XrData
- Submodules
- DataUtils
- DensitySpace
- DENSS
- Except
- FlowChange
- Guinier
- InterParticle
- Legacy
- Local
- LowRank
- Mapping
- PackageUtils
- Peaks
- PlotUtils
- Progress
- Reports
- Shapes
- Stats
- SurveyUtils
- Trimming