Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

sg_model_exceptions.py 671 B

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
  1. class UnsupportedTrainingParameterFormat(Exception):
  2. """Exception raised illegal training param format.
  3. Attributes:
  4. message -- explanation of the error
  5. """
  6. def __init__(self, desc):
  7. self.message = "Unsupported training parameter format: " + desc
  8. super().__init__(self.message)
  9. class UnsupportedOptimizerFormat(UnsupportedTrainingParameterFormat):
  10. """Exception raised illegal optimizer format.
  11. Attributes:
  12. message -- explanation of the error
  13. """
  14. def __init__(self):
  15. super().__init__(
  16. "optimizer parameter expected one of ['Adam','SGD','RMSProp'], or torch.optim.Optimizer object")
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...