Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update for ceci version 2 #12

Merged
merged 6 commits into from
Jul 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ classifiers = [
dynamic = ["version"]
dependencies = [
"deprecated",
"pz-rail-base",
"pz-rail-base>=1.0.3",
"scikit-learn",
"minisom",
"somoclu",
Expand Down
8 changes: 4 additions & 4 deletions src/rail/estimation/algos/minisom_som.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,10 @@ class MiniSOMInformer(CatInformer):
som_learning_rate=Param(float, 0.5, msg="SOM learning rate"),
som_iterations=Param(int, 10_000, msg="number of iterations in SOM training"))

def __init__(self, args, comm=None):
def __init__(self, args, **kwargs):
""" Constructor:
Do Informer specific initialization """
CatInformer.__init__(self, args, comm=comm)
super().__init__(args, **kwargs)
self.model = None

def run(self):
Expand Down Expand Up @@ -212,11 +212,11 @@ class MiniSOMSummarizer(SZPZSummarizer):
('cellid_output', TableHandle),
('uncovered_cell_file', TableHandle)]

def __init__(self, args, comm=None):
def __init__(self, args, **kwargs):
self.zgrid = None
self.model = None
self.usecols = None
SZPZSummarizer.__init__(self, args, comm=comm)
super().__init__(args, **kwargs)
self.som = None
self.column_usage = None
self.ref_column_name = None
Expand Down
8 changes: 4 additions & 4 deletions src/rail/estimation/algos/somoclu_som.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,10 +201,10 @@ class SOMocluInformer(CatInformer):
+ "Default: 1.5"),
som_learning_rate=Param(float, 0.5, msg="Initial SOM learning rate (scale0 param in Somoclu)"))

def __init__(self, args, comm=None):
def __init__(self, args, **kwargs):
""" Constructor:
Do Informer specific initialization """
CatInformer.__init__(self, args, comm=comm)
super().__init__(args, **kwargs)
self.model = None

def run(self):
Expand Down Expand Up @@ -329,11 +329,11 @@ class SOMocluSummarizer(SZPZSummarizer):
('cellid_output', Hdf5Handle),
('uncovered_cluster_file', TableHandle)]

def __init__(self, args, comm=None):
def __init__(self, args, **kwargs):
self.zgrid = None
self.model = None
self.usecols = None
SZPZSummarizer.__init__(self, args, comm=comm)
super().__init__(args, **kwargs)
self.som = None
self.column_usage = None
self.ref_column_name = None
Expand Down
Loading