summaryrefslogtreecommitdiff
path: root/torch/legacy/nn/Abs.py
diff options
context:
space:
mode:
Diffstat (limited to 'torch/legacy/nn/Abs.py')
-rw-r--r--torch/legacy/nn/Abs.py17
1 files changed, 9 insertions, 8 deletions
diff --git a/torch/legacy/nn/Abs.py b/torch/legacy/nn/Abs.py
index 475180af66..4b61c32041 100644
--- a/torch/legacy/nn/Abs.py
+++ b/torch/legacy/nn/Abs.py
@@ -1,24 +1,25 @@
import torch
from .Module import Module
+
class Abs(Module):
+
def __init__(self):
super(Abs, self).__init__()
def updateOutput(self, input):
self._backend.Abs_updateOutput(
- self._backend.library_state,
- input,
- self.output
+ self._backend.library_state,
+ input,
+ self.output
)
return self.output
def updateGradInput(self, input, gradOutput):
self._backend.Abs_updateGradInput(
- self._backend.library_state,
- input,
- gradOutput,
- self.gradInput
+ self._backend.library_state,
+ input,
+ gradOutput,
+ self.gradInput
)
return self.gradInput
-