Error with pytorch-sparse : interrupted by signal 11: SIGSEGV - pytorch

What could be the reason that program does not show any error:
from torch_geometric.nn import MessagePassing
File "/home/es/anaconda3/envs/pyg-meta/lib/python3.7/site-packages/torch_geometric/__init__.py", line 4, in <module>
import torch_geometric.data
File "/home/es/anaconda3/envs/pyg-meta/lib/python3.7/site-packages/torch_geometric/data/__init__.py", line 1, in <module>
from .data import Data
File "/home/es/anaconda3/envs/pyg-meta/lib/python3.7/site-packages/torch_geometric/data/data.py", line 20, in <module>
from torch_sparse import SparseTensor
File "/home/es/anaconda3/envs/pyg-meta/lib/python3.7/site-packages/torch_sparse/__init__.py", line 19, in <module>
torch.ops.load_library(spec.origin)
File "/home/es/anaconda3/envs/pyg-meta/lib/python3.7/site-packages/torch/_ops.py", line 255, in load_library
ctypes.CDLL(path)
File "/home/es/anaconda3/envs/pyg-meta/lib/python3.7/ctypes/__init__.py", line 364, in __init__
self._handle = _dlopen(self._name, mode)
OSError: /home/es/anaconda3/envs/pyg-meta/lib/python3.7/site-packages/torch_sparse/_spmm_cuda.so: undefined symbol: _ZNK3c1010TensorImpl36is_contiguous_nondefault_policy_implENS_12MemoryFormatE
Once I installed the following as mentioned in this page :
pip install torch-scatter==2.0.9 torch-sparse==0.6.12 torch-cluster==1.5.9 torch-spline-conv==1.2.1 torch-geometric -f https://data.pyg.org/whl/torch-1.9.0+cu111.html
It shows this and I do not know what is:
Process finished with exit code 139 (interrupted by signal 11: SIGSEGV)
How to resolve this?

Related

I cant install pgi in windows whit pip

I tried to install the pgi package in python but it won't let me and I get the following error:
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [22 lines of output]
Traceback (most recent call last):
File "<string>", line 2, in <module>
File "<pip-setuptools-caller>", line 34, in <module>
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\setup.py", line 18, in <module>
import pgi
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\pgi\__init__.py", line 10, in <module>
from .importer import require_version, get_required_version
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\pgi\importer.py", line 15, in <module>
from .clib.gir import GIRepository
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\pgi\clib\gir\__init__.py", line 8, in <module>
from .giargument import GIArgument
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\pgi\clib\gir\giargument.py", line 9, in <module>
from ..glib import gboolean, gint8, guint8, gint16, guint16, gint32, guint32
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\pgi\clib\glib.py", line 16, in <module>
_glib = find_library("glib-2.0")
File "C:\Users\javie\AppData\Local\Temp\pip-install-ebu1lkep\pgi_ba9aff7fc8974a6997ee57e6996d860c\pgi\clib\_utils.py", line 99, in find_library
_internal[name] = cdll.LoadLibrary(_so_mapping[name])
File "C:\Users\javie\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 452, in LoadLibrary
return self._dlltype(name)
File "C:\Users\javie\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 374, in __init__
self._handle = _dlopen(self._name, mode)
FileNotFoundError: Could not find module 'libglib-2.0-0.dll' (or one of its dependencies). Try using the full path with constructor syntax.
[end of output]
The command who i install:
pip install pgi

pytorch geometric: OSError: Symbol not found

could anyone please help me with the following error which appears when loading pytorch geometric (installed following PyTorch torch_sparse installation without CUDA)
Traceback (most recent call last):
File "training.py", line 8, in <module>
from models.gat import GATNet
File "/Users/xxx/yyy/models/gat.py", line 5, in <module>
from torch_geometric.nn import GATConv
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_geometric/__init__.py", line 5, in <module>
import torch_geometric.data
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_geometric/data/__init__.py", line 1, in <module>
from .data import Data
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_geometric/data/data.py", line 8, in <module>
from torch_sparse import coalesce, SparseTensor
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/__init__.py", line 15, in <module>
f'{library}_{suffix}', [osp.dirname(__file__)]).origin)
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch/_ops.py", line 104, in load_library
ctypes.CDLL(path)
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/ctypes/__init__.py", line 364, in __init__
self._handle = _dlopen(self._name, mode)
OSError: dlopen(/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/_convert_cpu.so, 6): Symbol not found: __ZN2at5emptyEN3c108ArrayRefIxEERKNS0_13TensorOptionsENS0_8optionalINS0_12MemoryFormatEEE
Referenced from: /Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/_convert_cpu.so
Expected in: /Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch/lib/libtorch_cpu.dylib
in /Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/_convert_cpu.so
I tried deleting anaconda, deleting my cache and reinstalling. But nothing seemed to help. It is macOS Catalina.
Thanks :)

Unable to train RASA-CORE Model throwing traceback :from google.protobuf.pyext import _message ImportError: DLL load failed: Access is denied

windows 10
Python 3.7.3
I am trying to train my rasa-core model using make commend and it's throwing below traceback in windows commandprompt:
I have tried running CMD as administrator and then training rasa-core model but it gives me same traceback. Can't find anything related to rasacore in internet so not sure if other solutions are relevant to this error
C:\Users\mrawat\starter-pack-rasa-stack>make train-core
python -m rasa_core.train -d domain.yml -s data/stories.md -o models/current/dialogue -c policies.yml
Traceback (most recent call last):
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 183, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 109, in _get_module_details
__import__(pkg_name)
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\rasa_core\__init__.py", line 6, in <module>
from rasa_core.test import test
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\rasa_core\test.py", line 19, in <module>
from rasa_core.policies.form_policy import FormPolicy
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\rasa_core\policies\__init__.py", line 1, in <module>
from rasa_core.policies.policy import Policy
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\rasa_core\policies\policy.py", line 3, in <module>
import tensorflow as tf
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\tensorflow\__init__.py", line 24, in <module>
from tensorflow.python import pywrap_tensorflow # pylint: disable=unused-import
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\tensorflow\python\__init__.py", line 52, in <module>
from tensorflow.core.framework.graph_pb2 import *
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\tensorflow\core\framework\graph_pb2.py", line 6, in <module>
from google.protobuf import descriptor as _descriptor
File "C:\Users\mrawat\AppData\Local\Programs\Python\Python37\lib\site-packages\google\protobuf\descriptor.py", line 47, in <module>
from google.protobuf.pyext import _message
ImportError: DLL load failed: Access is denied.
make: *** [train-core] Error 1
I believe protobuf 3.7.1 is not compatible with rasa-core starter pack model downgrading the protobuf==3.6.0 solved my problem in windows10 machine.
pip install protobuf==3.6.0
found details :Make train-core // Import Error : DDL Load failed

IPython Not opening (invalid syntax)

I have installed IPython using the command:
python3.7 -m pip install ipython
And it gave the prompt of successful installation as well but when i try to open IPython using the command:
python3.7 -m IPython
(NOTE: using IPython instead of ipython because that's how it is stored in my system)
I am getting the following error:
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 183, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "/usr/lib/python3.7/runpy.py", line 142, in _get_module_details
return _get_module_details(pkg_main_name, error)
File "/usr/lib/python3.7/runpy.py", line 109, in _get_module_details
__import__(pkg_name)
File "/usr/local/lib/python3.7/dist-packages/IPython/__init__.py", line 54, in <module>
from .core.application import Application
File "/usr/local/lib/python3.7/dist-packages/IPython/core/application.py", line 25, in <module>
from IPython.core import release, crashhandler
File "/usr/local/lib/python3.7/dist-packages/IPython/core/crashhandler.py", line 27, in <module>
from IPython.core import ultratb
File "/usr/local/lib/python3.7/dist-packages/IPython/core/ultratb.py", line 119, in <module>
from IPython.utils import path as util_path
File "/usr/local/lib/python3.7/dist-packages/IPython/utils/path.py", line 17, in <module>
from IPython.utils.process import system
File "/usr/local/lib/python3.7/dist-packages/IPython/utils/process.py", line 19, in <module>
from ._process_posix import system, getoutput, arg_split, check_pid
File "/usr/local/lib/python3.7/dist-packages/IPython/utils/_process_posix.py", line 23, in <module>
import pexpect
File "/usr/lib/python3/dist-packages/pexpect/__init__.py", line 75, in <module>
from .pty_spawn import spawn, spawnu
File "/usr/lib/python3/dist-packages/pexpect/pty_spawn.py", line 15, in <module>
from .spawnbase import SpawnBase
File "/usr/lib/python3/dist-packages/pexpect/spawnbase.py", line 218
def expect(self, pattern, timeout=-1, searchwindowsize=-1, async=False):
^
SyntaxError: invalid syntax
Download pexpect4.6 source code from https://github.com/pexpect/pexpect/releases/tag/4.6
Extract the source code, get into the folder and install the pexpect by:
sudo python3.7 setup.py install
This should solve your problem. :)

Getting DLL error with 'jupyter lab' command in Anaconda Installation

Getting DLL error with 'jupyter lab' command in Anaconda Installation:
Details for system:
conda 4.5.11
Python 3.7.0
jupyter 4.4.0
Height of weirdness is that I am able to launch jupyter lab from Anaconda Navigator, but 'jupyter lab' is not working and throwing below exception:
Traceback (most recent call last):
File "c:\ml\installed_tools\anaconda3\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "c:\ml\installed_tools\anaconda3\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\ML\installed_tools\anaconda3\Scripts\jupyter-lab.EXE\__main__.py", line 5, in <module>
File "c:\ml\installed_tools\anaconda3\lib\site-packages\jupyterlab\labapp.py", line 12, in <module>
from jupyterlab_server import slugify, WORKSPACE_EXTENSION
File "c:\ml\installed_tools\anaconda3\lib\site-packages\jupyterlab_server\__init__.py", line 4, in <module>
from .app import LabServerApp
File "c:\ml\installed_tools\anaconda3\lib\site-packages\jupyterlab_server\app.py", line 9, in <module>
from .server import ServerApp
File "c:\ml\installed_tools\anaconda3\lib\site-packages\jupyterlab_server\server.py", line 32, in <module>
from jupyter_server.serverapp import ServerApp, aliases, flags # noqa
File "c:\ml\installed_tools\anaconda3\lib\site-packages\jupyter_server\serverapp.py", line 46, in <module>
from zmq.eventloop import ioloop
File "c:\ml\installed_tools\anaconda3\lib\site-packages\zmq\__init__.py", line 47, in <module>
from zmq import backend
File "c:\ml\installed_tools\anaconda3\lib\site-packages\zmq\backend\__init__.py", line 40, in <module>
reraise(*exc_info)
File "c:\ml\installed_tools\anaconda3\lib\site-packages\zmq\utils\sixcerpt.py", line 34, in reraise
raise value
File "c:\ml\installed_tools\anaconda3\lib\site-packages\zmq\backend\__init__.py", line 27, in <module>
_ns = select_backend(first)
File "c:\ml\installed_tools\anaconda3\lib\site-packages\zmq\backend\select.py", line 27, in select_backend
mod = __import__(name, fromlist=public_api)
File "c:\ml\installed_tools\anaconda3\lib\site-packages\zmq\backend\cython\__init__.py", line 6, in <module>
from . import (constants, error, message, context,
ImportError: DLL load failed: The specified module could not be found.
Although I have posted this question, but now I also got a solution for the same.
Please add following in the path variable, it will be resolved thereafter (I just checked):
C:\ML\installed_tools\anaconda3 (was already present)
C:\ML\installed_tools\anaconda3\Scripts (was already present)
C:\ML\installed_tools\anaconda3\Library\bin (added now)
C:\ML\installed_tools\anaconda3\Library\mingw-w64\bin (added now)

Resources