Skip to content

Commit

Permalink
Ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
calebrob6 committed Sep 27, 2024
1 parent 4e268fc commit 63d346b
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions torchgeo/models/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,12 +111,11 @@ def get_weight(name: str) -> WeightsEnum:
The requested weight enum.
Raises:
ValueError: if `name` doesn't point to a valid WeightsEnum
ValueError: if `name` doesn't point to a valid WeightsEnum
"""
if name in _model_weights:
return _model_weights[name]
else:
sub_weights = {}
for name, weight_enum in _model_weights.items():
if isinstance(name, str):
for sub_weight_enum in weight_enum:
Expand Down

0 comments on commit 63d346b

Please sign in to comment.