Wassfast在Linux下运行过程
- 安装conda或者miniconda
- 下载Wassfast,安装git
$ sudo apt-get install git
$ git clone https://gitlab.com/fibe/wassfast.git
$ cd wassfast - conda env create -f environment_name
environment_name 根据安装的环境选择
如果conda安装失败,选择mamba进行安装
$ conda install -n base conda-forge::mamba
$ mamba env create -f environment_name - 如果使用PU模式运行,需要编译C++库
$ cd wassfast/PointsReducer
$ mkdir build
$ cd build
$ cmake …/
$ make ; make install - 激活环境
$ conda activate wassfast_cnn
$ python -m wassfast ./input /home/tai/desktop/wassfast/data/config256.mat ./config ./settings.cfg RLTB CNN --batchsize 16 -n 49 -r 15.0 -o output.nc - 在wassfast文件夹下下载数据并解压,激活环境后运行
$./run_wassfast_cnn.sh
如果报错 only integers, slices (:
), ellipsis (...
), and 1-d integer or boolean arrays are valid indices
在终端输入 export PYTHONWARNINGS=‘ignore:semaphore_tracker:UserWarning’ - 生成wassfast_output.nc后在数据文件夹下运行
$./run_wassncplot.sh
报错
DirectoryNotACondaEnvironmentError: The target directory exists, but it is not a conda environment.
Use ‘conda create’ to convert the directory to a conda environment.
target directory: /home/tai/miniconda3/envs/wassncplot
不知道什么原因,等解决了再更新。