-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'issue_586' of github.com:Delaunay/orion into issue_586
- Loading branch information
Showing
5 changed files
with
23 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,6 +25,7 @@ | |
"orion.serving", | ||
"orion.storage", | ||
"orion.testing", | ||
"orion.typing", | ||
] | ||
|
||
extras_require = { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,23 @@ | ||
import typing | ||
|
||
try: | ||
import torch | ||
|
||
if typing.TYPE_CHECKING: | ||
import torch | ||
HAS_TORCH = True | ||
TORCH_ERROR = None | ||
|
||
except ImportError as err: | ||
TORCH_ERROR = err | ||
HAS_TORCH = False | ||
|
||
class torch: | ||
"""torch module stub""" | ||
|
||
class nn: | ||
"""toch nn module stub""" | ||
|
||
class Module: | ||
"""torch module stub""" | ||
|
||
pass | ||
|
||
def __getattr__(self) -> None: | ||
raise err | ||
raise TORCH_ERROR |