Error in PyInstaller executable with Pytorch

I am trying to create an executable with pyinstaller from a python/conda environment. Although it is creating the executable but while running it is coming up with the following error
“OSError: Can’t get source for <class ‘torch_geometric.nn.pool.select.base.SelectOutput’>. TorchScript requires source access in order to carry out compilation, make sure original .py files are available.
[47898] Failed to execute script ‘start’ due to unhandled exception!”

I am using torch 2.0.1, torch geometric 2.5.3 and Pyinstaller 6.5.0

Have tried multiple solutions:-
Ranging from adding files, binaries of torch in .spec files and all. But it is not working.