Write TensorBoardInfo to the current process's info file. This should be called by `main` once the server is ready. When the server shuts down, `remove_info_file` should be called. Args: tensorboard_info: A valid `TensorBoardInfo` object. Raises: ValueError: If any fie
(tensorboard_info)
| 249 | |
| 250 | |
| 251 | def write_info_file(tensorboard_info): |
| 252 | """Write TensorBoardInfo to the current process's info file. |
| 253 | |
| 254 | This should be called by `main` once the server is ready. When the |
| 255 | server shuts down, `remove_info_file` should be called. |
| 256 | |
| 257 | Args: |
| 258 | tensorboard_info: A valid `TensorBoardInfo` object. |
| 259 | |
| 260 | Raises: |
| 261 | ValueError: If any field on `info` is not of the correct type. |
| 262 | """ |
| 263 | payload = "%s\n" % _info_to_string(tensorboard_info) |
| 264 | with open(_get_info_file_path(), "w") as outfile: |
| 265 | outfile.write(payload) |
| 266 | |
| 267 | |
| 268 | def remove_info_file(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…