Question:
Mindinsight uses error reporting on modelart.
After adding the summary and training some epoch normally, the operation will report an error:
Solution:
When using SummaryCollector, you need to put the code block in if__name__ == __main__:
The official mindspire tutorial has been updated. You can refer to the writing method of the latest tutorial: collect summary data – mindspire master document
Codes like this:
def train():
summary_collector = SummaryCollector(summary_dir='./summary_dir')
...
model.train(...., callback=[summary_collector])
if __name__ == '__main__':
train()
Read More:
- [Solved] RuntimeError An attempt has been made to start a new process
- [Solved] Python Error: An attempt has been made to start a new process before the current process has finished …
- [Solved] Error starting proxy server: oserror (10013), “an attempt was made to access the socket in a way that the access permission is not allowed.”, None, 10013, None)
- [Solved] RuntimeError: one of the variables needed for gradient computation has been modified by an inplace
- [Solved] AttributeError: module ‘thread‘ has no attribute ‘start_new_thread‘
- [Solved] pytorc Error: RuntimeError: one of the variables needed for gradient computation has been modified by an
- RuntimeError: Failed to register operator torchvision::_new_empty_tensor_op. +torch&torchversion Version Matching
- [Solved] PyQt: RuntimeError: wrapped C/C++ object has been deleted & has no attribute of flush in python
- [Solved] PyTorch Caught RuntimeError in DataLoader worker process 0和invalid argument 0: Sizes of tensors mus
- RuntimeError: CUDA error: an illegal memory access was encountered
- How to Solve Error: Unverified HTTPS request is being made
- [Solved] Jupyter Notebook Start Error: Fatal error in launcher: Unable to create process using
- Pytorch torch.cuda.FloatTensor Error: RuntimeError: one of the variables needed for gradient computation has…
- [Solved] RuntimeError: No application found. Either work inside a view function or push an application contex
- [Solved] glove Error: RuntimeError: Vector for token b‘Strangeling‘ has 17 dimensions
- When sending an email, an error was reported: AttributeError:’list’ object has no attribute’encode’
- [Solved] pytorch loss.backward() Error: RuntimeError: Function AddBackward0 returned an invalid gradient at index 1…
- [Solved] Pytorch Error: RuntimeError: Error(s) in loading state_dict for Network: size mismatch
- [Solved] RuntimeError: a view of a leaf Variable that requires grad is being used in an in-place
- [Solved] RuntimeError: a view of a leaf Variable that requires grad is being used in an in-place operation