Spaces:
Runtime error
Runtime error
Download models/abs_model.py from phuclhsilverai/SSN: direct link, hf CLI and curl.
- Browser
- Download file 1.27 kB
-
https://huggingface.co/spaces/phuclhsilverai/SSN/resolve/main/models/abs_model.py
- Command line
-
hf download hf://spaces/phuclhsilverai/SSN/models/abs_model.py
-
curl -L -o abs_model.py https://huggingface.co/spaces/phuclhsilverai/SSN/resolve/main/models/abs_model.py
1.27 kB
| from abc import ABC, abstractmethod | |
| from collections import OrderedDict | |
| class abs_model(ABC): | |
| """ Training Related Interface | |
| """ | |
| def setup_input(self, x): | |
| pass | |
| def forward(self, x): | |
| pass | |
| def supervise(self, input_x, y, is_training:bool)->float: | |
| pass | |
| def get_visualize(self) -> OrderedDict: | |
| return {} | |
| """ Inference Related Interface | |
| """ | |
| def inference(self, x): | |
| pass | |
| def batch_inference(self, x): | |
| pass | |
| """ Logging/Visualization Related Interface | |
| """ | |
| def get_logs(self): | |
| pass | |
| """ Getter & Setter | |
| """ | |
| def get_models(self) -> dict: | |
| """ GAN may have two models | |
| """ | |
| pass | |
| def get_optimizers(self) -> dict: | |
| """ GAN may have two optimizer | |
| """ | |
| pass | |
| def set_models(self, models) -> dict: | |
| """ GAN may have two models | |
| """ | |
| pass | |
| def set_optimizers(self, optimizers: dict): | |
| """ GAN may have two optimizer | |
| """ | |
| pass | |