From b5d0f35196ec395dff8772d1ae223e5305c2f7a7 Mon Sep 17 00:00:00 2001 From: David Rotermund Date: Wed, 10 Jul 2024 16:01:51 +0200 Subject: [PATCH] Delete SplitOnOffLayer.py --- SplitOnOffLayer.py | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100644 SplitOnOffLayer.py diff --git a/SplitOnOffLayer.py b/SplitOnOffLayer.py deleted file mode 100644 index cff150b..0000000 --- a/SplitOnOffLayer.py +++ /dev/null @@ -1,23 +0,0 @@ -import torch - - -class SplitOnOffLayer(torch.nn.Module): - - def __init__( - self, - ) -> None: - super().__init__() - - #################################################################### - # Forward # - #################################################################### - - def forward(self, input: torch.Tensor) -> torch.Tensor: - assert input.ndim == 4 - - temp = input - 0.5 - temp_a = torch.nn.functional.relu(temp) - temp_b = torch.nn.functional.relu(-temp) - output = torch.cat((temp_a, temp_b), dim=1) - - return output