blcuicall / BLCU-HPC

高性能GPU计算集群
6 stars 0 forks source link

学长,请问能否帮个忙,在集群上安装一个 叫 libsndfile 的linux软件 #14

Closed ywh-my closed 2 years ago

ywh-my commented 2 years ago

在使用语音处理库torchaudio的时候遇到这个问题: import torch,torchaudio,math raise OSError('sndfile library not found') OSError: sndfile library not found 这个import 在cpu上直接运行(不使用slurm)的时候并不会报错。但是在 提交sbatch任务后,代码在计算结点执行却会报错 目前我也不清楚到底怎么解决, 但是查百度说可以安装 libsndfile 包 。希望先安装这个 这是在 依赖库 soundfile官网找到的解决办法: Installation SoundFile depends on the Python packages CFFI and NumPy, and the system library libsndfile.

In a modern Python, you can use pip install soundfile to download and install the latest release of SoundFile and its dependencies. On Windows and OS X, this will also install the library libsndfile. On Linux, you need to install libsndfile using your distribution’s package manager, for example sudo apt-get install libsndfile1.

chongruining commented 2 years ago

libsndfile目前是已安装的 libsndfile1 is already the newest version (1.0.28-7ubuntu0.1). 0 upgraded, 0 newly installed, 0 to remove and 9 not upgraded.

ywh-my commented 2 years ago

您好,在计算节点上使用不了libsndfile。 请问是否计算节点没有装这个软件?

ywh-my commented 2 years ago

在管理节点 可以运行 import librosa (也是一个语音处理库) 但是在计算机结点却运行不了,报错: import librosa import soundfile as sf raise OSError('sndfile library not found') OSError: sndfile library not found

chongruining commented 2 years ago

我在计算节点上都安装了一遍,测试了下现在是可以正常引入,请检查下还有没有其他问题

ywh-my commented 2 years ago

现在没问题了。感谢。 有时候怀疑是 sbatch的问题,用srun之后就可以了

chongruining commented 2 years ago

OK~