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

remove raise_nones #129

Merged
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
8 changes: 0 additions & 8 deletions molpipeline/pipeline/_molpipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ def __init__(
element_list: list[ABCPipelineElement],
n_jobs: int = 1,
name: str = "MolPipeline",
raise_nones: bool = False,
) -> None:
"""Initialize MolPipeline.

Expand All @@ -53,8 +52,6 @@ def __init__(
Number of cores used.
name: str
Name of pipeline.
raise_nones: bool
If True, raise an error if a None is encountered in the pipeline.

Returns
-------
Expand All @@ -66,7 +63,6 @@ def __init__(
self._requires_fitting = any(
element.requires_fitting for element in self._element_list
)
self.raise_nones = raise_nones

@property
def _filter_elements(self) -> list[ErrorFilter]:
Expand Down Expand Up @@ -157,13 +153,11 @@ def get_params(self, deep: bool = True) -> dict[str, Any]:
"element_list": self.element_list,
"n_jobs": self.n_jobs,
"name": self.name,
"raise_nones": self.raise_nones,
}
return {
"element_list": self._element_list,
"n_jobs": self.n_jobs,
"name": self.name,
"raise_nones": self.raise_nones,
}

def set_params(self, **parameter_dict: Any) -> Self:
Expand All @@ -185,8 +179,6 @@ def set_params(self, **parameter_dict: Any) -> Self:
self.n_jobs = int(parameter_dict["n_jobs"])
if "name" in parameter_dict:
self.name = str(parameter_dict["name"])
if "raise_nones" in parameter_dict:
self.raise_nones = bool(parameter_dict["raise_nones"])
return self

@property
Expand Down