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

[Code Cleanup] [Low priority] Unnecessary Check #176

Open
ArlindKadra opened this issue Apr 20, 2021 · 0 comments
Open

[Code Cleanup] [Low priority] Unnecessary Check #176

ArlindKadra opened this issue Apr 20, 2021 · 0 comments
Labels
refactoring Improvement of readability and abstract codes

Comments

@ArlindKadra
Copy link

if isinstance(self.resampling_strategy, CrossValTypes):
self.cv_models_ = self._backend.load_cv_models_by_identifiers(identifiers)
if isinstance(self.resampling_strategy, CrossValTypes):
if len(self.cv_models_) == 0:
raise ValueError('No models fitted!')

The second if check at Line 433 is not needed. We can just continue with the statements under the first.

@ArlindKadra ArlindKadra added the refactoring Improvement of readability and abstract codes label Apr 20, 2021
@ArlindKadra ArlindKadra changed the title [Code Cleanup] Low priority [Code Cleanup] [Low priority] Unnecessary Check Apr 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactoring Improvement of readability and abstract codes
Projects
None yet
Development

No branches or pull requests

1 participant