(self, log_dir: str)
| 10 | """ |
| 11 | |
| 12 | def __init__(self, log_dir: str): # Store log in log_dir |
| 13 | |
| 14 | self._log_dir = log_dir |
| 15 | self._logs = dict() |
| 16 | |
| 17 | # Ensure the directories exist |
| 18 | if not os.path.isdir(self.log_dir): |
| 19 | os.mkdir(self.log_dir) |
| 20 | if not os.path.isdir(self.metadata_dir): |
| 21 | os.mkdir(self.metadata_dir) |
| 22 | if not os.path.isdir(self.checkpoint_dir): |
| 23 | os.mkdir(self.checkpoint_dir) |
| 24 | open(self.log_dir + '/log.txt', 'w').close() #make log file empty if it already exists |
| 25 | |
| 26 | @property |
| 27 | def log_dir(self): |
nothing calls this directly
no outgoing calls
no test coverage detected