Conda installers available!

More
4 years 11 months ago #2175 by matthiash
I'm not (yet) a conda expert, but I think your given hint is wrong. That's the path to the uninstalled package.
For me a hint is not necessary, conda sets PATH appropriately such that cmake finds Netgen/NGSolve automatically:
Code:
Netgen_DIR:PATH=/home/mhochsteger/miniconda3/envs/ngs/lib/cmake/netgen NGSolve_DIR:PATH=/home/mhochsteger/miniconda3/envs/ngs/lib/cmake/ngsolve
More
4 years 11 months ago - 4 years 11 months ago #2176 by creativeworker
Ok, i see it has something to do with the path variables.
FYI: I created an own conda environment for the NGSolve installation. Activating it in the shell gives the possibility to open netgen just by typing netgen to the terminal. That works.

But I can't find any Path variables as you showed in the post? The second thing is then to apply those environment variables of the conda environment to CLion, where cmake is started.

For curiosity I installed netgen via the classical way. Then the C++ Extension compiles as expected, but of course installs into the 'old' structure, which is then not used with the conda package (of course as expected).

P.S.: The update of netgen and ngsolve with conda worked flawless.
Last edit: 4 years 11 months ago by creativeworker.
More
4 years 11 months ago - 4 years 11 months ago #2179 by christopher
Did you have the conda environment activated when you ran the cmake configure?
I think this is the problem because you configure in clion. Maybe it is already enough to run clion in the venv. If not maybe run the cmake command by hand in the venv.
If you don't have it activated it won't find it, if you have it activated it should correctly install it into the virtual env as well.
Best
Christopher
Last edit: 4 years 11 months ago by christopher.
More
4 years 11 months ago #2180 by christopher
Btw you will most likely have to install the conda package pybind11 as well if you want to compile an ngsolve extension in a conda env.
Best
More
4 years 11 months ago #2195 by liubenyuan
Hi, thanks for the ngsolve conda cloud.

However, it seems like libngsolve.so or some dynamic libraries are not properly installed. For example,
Code:
import netgen.gui from ngsolve import * ERROR:root:Cannot activate multiple GUI eventloops optfile ./ng.opt does not exist - using default values togl-version : 2 OCC module loaded loading ngsolve library cannot load ngsolve error: couldn't load file "libngsolve.so": libngsolve.so: cannot open shared object file: No such file or directory

libngsolve.so is placed at /usr/share/miniconda3/pkgs/ngsolve-6.2.1909-py37_91/lib/netgen Maybe we should add an script telling its location whenever we reinstalled a new version of ngsolve.
More
4 years 11 months ago - 4 years 11 months ago #2200 by matthiash
Thanks for the report. We are currently working on an issue that is probably related to yours. A workaround is to set the LD_PRELOAD environment variable to the tcl library. In my case it's working by starting python like this:
Code:
LD_PRELOAD=/home/mhochsteger/miniconda3/lib/libtcl8.6.so python3

Anyway I would like to check the directory structure of your installation. Pleases post the output of following commands:
Code:
python3 -c "import netgen;print(netgen.__file__)"
Code:
python3 -c "import ngsolve;print(ngsolve.__file__)"

Best,
Matthias
Last edit: 4 years 11 months ago by matthiash.
Time to create page: 0.121 seconds