Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/r/69.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
在R网状结构中找不到python共享库_Python_R_Linux_Shared Libraries_Reticulate - Fatal编程技术网

在R网状结构中找不到python共享库

在R网状结构中找不到python共享库,python,r,linux,shared-libraries,reticulate,Python,R,Linux,Shared Libraries,Reticulate,我无法使R中的网状包正常工作 它找不到所需的共享LIBPYTHON文件,无论我通过module load加载了哪个版本的Python,或者我告诉netracite直接在R中使用哪个版本的Python 我正在研究University的集群,它安装了多个版本的Python,并通过模块加载 谢谢你的帮助 a) 使用2.7.9版(模块加载CBC的默认版本): b) 使用2.7.10版,在R中指定网状结构: > reticulate::use_python("/opt/Python/Python-2

我无法使R中的
网状
包正常工作

它找不到所需的共享
LIBPYTHON
文件,无论我通过
module load
加载了哪个版本的Python,或者我告诉
netracite
直接在R中使用哪个版本的Python

我正在研究University的集群,它安装了多个版本的Python,并通过模块加载

谢谢你的帮助

a) 使用2.7.9版(模块加载CBC的默认版本)

b) 使用2.7.10版,在R中指定网状结构:

> reticulate::use_python("/opt/Python/Python-2.7.10/bin/python2")
> reticulate::py_discover_config()

/opt/Python/Python-2.7.10/bin/python: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory
Error in system2(command = python, args = paste0("\"", config_script,  :
  error in running command

> system("which python")

/opt/Python/Python-2.7.10/bin/python

> library(reticulate)
> py_discover_config()
'import site' failed; use -v for traceback
Traceback (most recent call last):
  File "/home/csandoval/R/x86_64-pc-linux-gnu-library/3.5/reticulate/config/config.py", line 3, in <module>
    import os
  File "/opt/Python/Python-2.7.10/lib/python2.7/os.py", line 400, in <module>
    import UserDict
  File "/opt/Python/Python-2.7.10/lib/python2.7/UserDict.py", line 84, in <module>
    _abcoll.MutableMapping.register(IterableUserDict)
  File "/opt/Python/Python-2.7.10/lib/python2.7/abc.py", line 109, in register
    if issubclass(subclass, cls):
  File "/opt/Python/Python-2.7.10/lib/python2.7/abc.py", line 184, in __subclasscheck__
    cls._abc_negative_cache.add(subclass)
  File "/opt/Python/Python-2.7.10/lib/python2.7/_weakrefset.py", line 86, in add
    self.data.add(ref(item, self._remove))
TypeError: cannot create weak reference to 'classobj' object
Error in python_config(python_version, required_module, python_versions) :
  Error 1 occurred running /usr/bin/python
In addition: Warning message:
In system2(command = python, args = paste0("\"", config_script,  :
  running command ''/usr/bin/python' "/home/csandoval/R/x86_64-pc-linux-gnu-library/3.5/reticulate/config/config.py"' had status 1
c) 使用版本2.7.10,在启动R/loading
Networkite
之前运行模块load CBC python/2.7.10

> reticulate::use_python("/opt/Python/Python-2.7.10/bin/python2")
> reticulate::py_discover_config()

/opt/Python/Python-2.7.10/bin/python: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory
Error in system2(command = python, args = paste0("\"", config_script,  :
  error in running command

> system("which python")

/opt/Python/Python-2.7.10/bin/python

> library(reticulate)
> py_discover_config()
'import site' failed; use -v for traceback
Traceback (most recent call last):
  File "/home/csandoval/R/x86_64-pc-linux-gnu-library/3.5/reticulate/config/config.py", line 3, in <module>
    import os
  File "/opt/Python/Python-2.7.10/lib/python2.7/os.py", line 400, in <module>
    import UserDict
  File "/opt/Python/Python-2.7.10/lib/python2.7/UserDict.py", line 84, in <module>
    _abcoll.MutableMapping.register(IterableUserDict)
  File "/opt/Python/Python-2.7.10/lib/python2.7/abc.py", line 109, in register
    if issubclass(subclass, cls):
  File "/opt/Python/Python-2.7.10/lib/python2.7/abc.py", line 184, in __subclasscheck__
    cls._abc_negative_cache.add(subclass)
  File "/opt/Python/Python-2.7.10/lib/python2.7/_weakrefset.py", line 86, in add
    self.data.add(ref(item, self._remove))
TypeError: cannot create weak reference to 'classobj' object
Error in python_config(python_version, required_module, python_versions) :
  Error 1 occurred running /usr/bin/python
In addition: Warning message:
In system2(command = python, args = paste0("\"", config_script,  :
  running command ''/usr/bin/python' "/home/csandoval/R/x86_64-pc-linux-gnu-library/3.5/reticulate/config/config.py"' had status 1