Modules that have backward hooks assigned cannot be compiled

When I’m calling the .fit function on the lightning module’s object, I’m getting this error.
I’ve tried using a simple single convolution layer and I’m not using any forward or backward hooks.

I was trying to pinpoint the origin of this problem and found out its realted to the log_graph of tensorboard.
TensorBoardLogger(hparams.tblog_path, name=hparams.run_name, log_graph=True)
If I run the same code with log_graph as False, then I’m not getting such an error.

Any idea what could be causing this issue?
Thanks :slight_smile: