From e00cca87f8815a460a2a9d43404349a9d648a113 Mon Sep 17 00:00:00 2001 From: Drew Oldag Date: Thu, 2 Nov 2023 12:38:46 -0700 Subject: [PATCH 1/5] Scaffolding to get basic files in place. --- pyproject.toml | 4 +++- src/rail/deepdisc/__init__.py | 2 -- src/rail/deepdisc/rail_deepdisc.py | 24 ++++++++++++++++++++++++ 3 files changed, 27 insertions(+), 3 deletions(-) create mode 100644 src/rail/deepdisc/rail_deepdisc.py diff --git a/pyproject.toml b/pyproject.toml index 56dc8f1..66d45c7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -16,7 +16,9 @@ classifiers = [ ] dynamic = ["version"] -dependencies = [] +dependencies = [ + "deepdisc @ git+ssh://git@github/com/lincc-frameworks/deepdisc", +] # On a mac, install optional dependencies with `pip install '.[dev]'` (include the single quotes) [project.optional-dependencies] diff --git a/src/rail/deepdisc/__init__.py b/src/rail/deepdisc/__init__.py index 0588fc3..f9a0d32 100644 --- a/src/rail/deepdisc/__init__.py +++ b/src/rail/deepdisc/__init__.py @@ -1,3 +1 @@ -from ._version import __version__ - from rail.estimation.algos.deepdisc import * diff --git a/src/rail/deepdisc/rail_deepdisc.py b/src/rail/deepdisc/rail_deepdisc.py new file mode 100644 index 0000000..9602309 --- /dev/null +++ b/src/rail/deepdisc/rail_deepdisc.py @@ -0,0 +1,24 @@ +from rail.estimation.estimator import CatEstimator, CatInformer + +class DeepDiscInformer(CatInformer): + """Placeholder for informer stage class""" + + name = "DeepDiscInformer" + config_options = CatInformer.config_options.copy() + + def __init__(self, args, comm=None): + CatInformer.__init__(self, args, comm=comm) + + def run(self): + pass + + +class DeepDiscEstimator(CatEstimator): + name = "DeepDiscEstimator" + config_options = CatEstimator.config_options.copy() + + def __init__(self, args, comm=None): + CatEstimator.__init__(self, args, comm=comm) + + def _process_chunk(self, start, end, data, first): + pass From 3e8e89b1ae67a0a52c4cfd578ec2f24117b4bab5 Mon Sep 17 00:00:00 2001 From: Drew Oldag Date: Thu, 2 Nov 2023 12:45:07 -0700 Subject: [PATCH 2/5] Trying to correct the dependency definition. --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 66d45c7..3582866 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -17,7 +17,7 @@ classifiers = [ dynamic = ["version"] dependencies = [ - "deepdisc @ git+ssh://git@github/com/lincc-frameworks/deepdisc", + "deepdisc @ git+ssh://git@github/com/lincc-frameworks/deepdisc.git", ] # On a mac, install optional dependencies with `pip install '.[dev]'` (include the single quotes) From 421a329316d78221495a4610d47b08725633d709 Mon Sep 17 00:00:00 2001 From: grantmerz Date: Thu, 2 Nov 2023 15:40:36 -0500 Subject: [PATCH 3/5] fix deepdisc dependency --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3582866..569643d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -17,7 +17,7 @@ classifiers = [ dynamic = ["version"] dependencies = [ - "deepdisc @ git+ssh://git@github/com/lincc-frameworks/deepdisc.git", + "deepdisc@git+https://github.com/lincc-frameworks/deepdisc.git", ] # On a mac, install optional dependencies with `pip install '.[dev]'` (include the single quotes) From 36b6ca3993cb164d6a5ce23cc9d062cd16836676 Mon Sep 17 00:00:00 2001 From: grantmerz Date: Thu, 2 Nov 2023 15:47:37 -0500 Subject: [PATCH 4/5] move files --- src/rail/deepdisc/rail_deepdisc.py | 24 ------------------------ src/rail/estimation/algos/deepdisc.py | 24 ++++++++++++++++++++++++ 2 files changed, 24 insertions(+), 24 deletions(-) delete mode 100644 src/rail/deepdisc/rail_deepdisc.py diff --git a/src/rail/deepdisc/rail_deepdisc.py b/src/rail/deepdisc/rail_deepdisc.py deleted file mode 100644 index 9602309..0000000 --- a/src/rail/deepdisc/rail_deepdisc.py +++ /dev/null @@ -1,24 +0,0 @@ -from rail.estimation.estimator import CatEstimator, CatInformer - -class DeepDiscInformer(CatInformer): - """Placeholder for informer stage class""" - - name = "DeepDiscInformer" - config_options = CatInformer.config_options.copy() - - def __init__(self, args, comm=None): - CatInformer.__init__(self, args, comm=comm) - - def run(self): - pass - - -class DeepDiscEstimator(CatEstimator): - name = "DeepDiscEstimator" - config_options = CatEstimator.config_options.copy() - - def __init__(self, args, comm=None): - CatEstimator.__init__(self, args, comm=comm) - - def _process_chunk(self, start, end, data, first): - pass diff --git a/src/rail/estimation/algos/deepdisc.py b/src/rail/estimation/algos/deepdisc.py index e69de29..9602309 100644 --- a/src/rail/estimation/algos/deepdisc.py +++ b/src/rail/estimation/algos/deepdisc.py @@ -0,0 +1,24 @@ +from rail.estimation.estimator import CatEstimator, CatInformer + +class DeepDiscInformer(CatInformer): + """Placeholder for informer stage class""" + + name = "DeepDiscInformer" + config_options = CatInformer.config_options.copy() + + def __init__(self, args, comm=None): + CatInformer.__init__(self, args, comm=comm) + + def run(self): + pass + + +class DeepDiscEstimator(CatEstimator): + name = "DeepDiscEstimator" + config_options = CatEstimator.config_options.copy() + + def __init__(self, args, comm=None): + CatEstimator.__init__(self, args, comm=comm) + + def _process_chunk(self, start, end, data, first): + pass From 8fce560f0f2a2cf06faa5bea7663fb90fa6eb6bd Mon Sep 17 00:00:00 2001 From: Drew Oldag Date: Thu, 2 Nov 2023 14:49:47 -0700 Subject: [PATCH 5/5] Adding trivial placeholder test. --- tests/deepdisc/test_placeholder.py | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 tests/deepdisc/test_placeholder.py diff --git a/tests/deepdisc/test_placeholder.py b/tests/deepdisc/test_placeholder.py new file mode 100644 index 0000000..3ada1ee --- /dev/null +++ b/tests/deepdisc/test_placeholder.py @@ -0,0 +1,2 @@ +def test_placeholder(): + assert True