Download model/layer.py from iaecpsu-1/tdce-basic: direct link, hf CLI and curl.
- Browser
- Download file 498 Bytes
-
https://huggingface.co/iaecpsu-1/tdce-basic/resolve/main/model/layer.py
- Command line
-
hf download hf://iaecpsu-1/tdce-basic/model/layer.py
-
curl -L -o layer.py https://huggingface.co/iaecpsu-1/tdce-basic/resolve/main/model/layer.py
498 Bytes
| # Base Class Layer | |
| class Layer: | |
| def __init__(self): | |
| self.input = None | |
| self.output = None | |
| self.time_usage = None | |
| # compute the output of a layer for a given input | |
| def forward_propagation(self, input): | |
| raise NotImplementedError | |
| # conpute dE/dX for a given dE/dY (and update parameters if any) | |
| def backward_propagation(self, output_error, learning_rate): | |
| raise NotImplementedError | |
| def predict(self): | |
| raise NotImplementedError | |