Skip to content

Commit

Permalink
hopefully fixes everything, ahain now
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim Locke committed Jul 12, 2024
1 parent 790ed89 commit 8fc9357
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions src/safeds/ml/nn/layers/_convolutional2d_layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,13 @@
from typing import TYPE_CHECKING, Any, Literal

from safeds._utils import _structural_hash
from safeds.ml.nn.typing import TensorShape

from ._layer import Layer

if TYPE_CHECKING:
from torch import nn

from safeds.ml.nn.typing import ModelImageSize
from safeds.ml.nn.typing import ModelImageSize, TensorShape


class Convolutional2DLayer(Layer):
Expand Down
2 changes: 1 addition & 1 deletion src/safeds/ml/nn/layers/_pooling2d_layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def __sizeof__(self) -> int:
+ sys.getsizeof(self._padding)
)

def get_parameter_count(self, input_size: TensorShape) -> int:
def get_parameter_count(self, input_size: TensorShape) -> int: # noqa: ARG002
return 0


Expand Down
2 changes: 1 addition & 1 deletion src/safeds/ml/nn/typing/_tensor_shape.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def get_size(self, dimension: int | None = None) -> int:
#TODO maybe add error message indicating that the dimension is out of range
return 0
if(dimension is None):
return self._dims
return self._dims[0]
return self._dims[dimension]

def __hash__(self) -> int:
Expand Down

0 comments on commit 8fc9357

Please sign in to comment.