From abfa5a77037053e91c39dc88b2bc7a06fd265c92 Mon Sep 17 00:00:00 2001 From: swittl <simon.wittl@th-deg.de> Date: Mon, 11 Nov 2024 22:11:12 +0100 Subject: [PATCH] added as dict --- pyproject.toml | 4 ++-- src/cyxtrax/simulation/model/augemtation_parameters.py | 8 ++++++++ uv.lock | 4 ++-- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 7ad038c..745d047 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -8,10 +8,10 @@ authors = [ ] requires-python = ">=3.10" dependencies = [ - "artistlib ; sys_platform == 'windows'", + "artistlib ; sys_platform == 'win32'", "dm-pix>=0.4.3", "h5py>=3.12.1", - "jax>=0.4.35 ; sys_platform == 'windows'", + "jax>=0.4.35 ; sys_platform == 'win32'", "jax[cuda12]>=0.4.35 ; sys_platform == 'linux'", "matplotlib>=3.9.2", "numpy>=2.1.3", diff --git a/src/cyxtrax/simulation/model/augemtation_parameters.py b/src/cyxtrax/simulation/model/augemtation_parameters.py index e478c5b..d3514b1 100644 --- a/src/cyxtrax/simulation/model/augemtation_parameters.py +++ b/src/cyxtrax/simulation/model/augemtation_parameters.py @@ -7,3 +7,11 @@ class AugemntationParameter: augmentation_function: str function_parameter: dict input_parameter: dict + + def as_dict(self): + return dict( + augmentation_module=self.augmentation_module, + augmentation_function=self.augmentation_function, + function_parameter=self.function_parameter, + input_parameter=self.input_parameter, + ) diff --git a/uv.lock b/uv.lock index 05ae03d..2b921bf 100644 --- a/uv.lock +++ b/uv.lock @@ -123,7 +123,7 @@ name = "cyxtrax" version = "0.1.0" source = { editable = "." } dependencies = [ - { name = "artistlib", marker = "sys_platform == 'windows'" }, + { name = "artistlib", marker = "sys_platform == 'win32'" }, { name = "dm-pix" }, { name = "h5py" }, { name = "jax", marker = "sys_platform == 'linux' or sys_platform == 'windows'" }, @@ -137,7 +137,7 @@ dependencies = [ [package.metadata] requires-dist = [ - { name = "artistlib", marker = "sys_platform == 'windows'", git = "https://github.com/wittlsn/aRTist-PythonLib" }, + { name = "artistlib", marker = "sys_platform == 'win32'", git = "https://github.com/wittlsn/aRTist-PythonLib" }, { name = "dm-pix", specifier = ">=0.4.3" }, { name = "h5py", specifier = ">=3.12.1" }, { name = "jax", marker = "sys_platform == 'windows'", specifier = ">=0.4.35" }, -- GitLab