Pointnet_Pointnet2_pytorch
Pointnet_Pointnet2_pytorch copied to clipboard
Pytorch Profiler does not work on the training script
Hi there, for the purpose of profiling the network, I modify the training bit so that it is wrapped in an "with ... as profiler" head following the Pytorch tutorial. However the training process stuck when I tried to print(profiler.table()).
I am wondering if there is any detail that I have missed, and would it be possible to release a training script that includes the profiler? Thanks a bunch.
As attached is a segment of my code. And the file
with torch.profiler.profile(activities=[torch.profiler.ProfilerActivity.CPU, torch.profiler.ProfilerActivity.CUDA,], profile_memory=True, with_stack=False, use_cuda=True,) as profiler:
for epoch in range(start_epoch, args.epoch):
...
log_string(profiler.table())