forked from Photon-AI-Research/NeuralSolvers
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4b7fcae
commit 81e6641
Showing
25 changed files
with
1,633 additions
and
103 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
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 |
---|---|---|
@@ -0,0 +1,45 @@ | ||
from abc import ABC, abstractmethod | ||
|
||
|
||
class LoggerInterface(ABC): | ||
|
||
@abstractmethod | ||
def log_scalar(self, scalar, name, epoch): | ||
""" | ||
Method that defines how scalars are logged | ||
Args: | ||
scalar: scalar to be logged | ||
name: name of the scalar | ||
epoch: epoch in the training loop | ||
""" | ||
pass | ||
|
||
@abstractmethod | ||
def log_image(self, image, name, epoch): | ||
""" | ||
Method that defines how images are logged | ||
Args: | ||
image: image to be logged | ||
name: name of the image | ||
epoch: epoch in the training loop | ||
""" | ||
pass | ||
|
||
@abstractmethod | ||
def log_histogram(self, histogram, name, epoch): | ||
""" | ||
Method that defines how images are logged | ||
Args: | ||
histogram: histogram to be logged | ||
name: name of the histogram | ||
epoch: epoch in the training loop | ||
""" | ||
pass | ||
|
||
|
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
Oops, something went wrong.