yolact
yolact copied to clipboard
Is there a possible way to visualize the graph of yolact?
Is there a possible way to visualize the graph of yolact? I tried tensorboard but it failed with an error saying,
File "/home/emjay/Install/anaconda3/envs/torch/lib/python3.7/site-packages/torch/jit/init.py", line 997, in trace_module module._c._create_method_from_trace(method_name, func, example_inputs, var_lookup_fn, _force_outplace) RuntimeError: Only tensors or tuples of tensors can be output from traced functions (getOutput at /opt/conda/conda-bld/pytorch_1570910687650/work/torch/csrc/jit/tracer.cpp:209)
I followed the steps on the following website. https://www.endtoend.ai/blog/pytorch-tensorboard/
and added the following lines into the train.py, right next to the data_loader assignments.
writer = SummaryWriter() datum = next(iter(data_loader)) images, targets, masks, num_crowds = prepare_data(args, datum) # out = net(images)
grid = torchvision.utils.make_grid(images)
writer.add_image('images', grid, 0)
writer.add_graph(net, images)
writer.close()
Any idea?
That's a JIT error, maybe try disabling JIT? Run it with
PYTORCH_JIT=0 python train.py <etc>
Then it comes with an error saying like this. AttributeError: 'Yolact' object has no attribute 'graph'
¯\_(ツ)_/¯
Might want to check the code for tensorboard and debug from there. I'm not familiar, so I don't think I'd be able to give much help.
I see. Thank you anyway. BTW, I love this emoticon (ツ)
Is there any update for this issue? I have encountered the same error.