Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: module 'libra_py' has no attribute 'Gaussian_methods' #203

Open
PaulYin28 opened this issue Feb 5, 2024 · 2 comments
Open

Comments

@PaulYin28
Copy link

Hi,
I have successfully compiled libra-code (v5.5.0) with anaconda in following steps:

conda remove --name libra --all  
conda create -n libra python=3.7
conda activate libra
conda install -y -c conda-forge numpy scipy matplotlib imageio jupyter_core
conda install -y ipykernel
conda install -y -c rmg py3dmol
#Next, all what we actually need:
conda install -y conda-build make
conda install -y -c conda-forge gcc_linux-64=12.2.0 gxx_linux-64=12.2.0 cmake=3.24.2 boost=1.80.0 python-devtools llvm-openmp
conda install -y -c conda-forge/label/gcc7 eigen mpfr
conda install -y -c psi4/label/dev libint2=2.7.1
conda install -y -c anaconda h5py gmp
cd ~/app/
git clone https://github.com/Quantum-Dynamics-Hub/libra-code.git libra
cd libra
git checkout devel
mkdir _build && cd _build && cmake ../
make -j4  
export PYTHONPATH=/home/mpiusr/app/libra/_build/src:$PYTHONPATH

But, I encountered some issues when I run the test jobs in libra-code, the following errors appear:

(libra) [mpiusr@ws1 test_1_init_system]$ python run_test.py 

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for boost::python::detail::container_element<std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > >, unsigned long, boost::python::detail::final_vector_derived_policies<std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > >, false> > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for std::vector<std::vector<float, std::allocator<float> >, std::allocator<std::vector<float, std::allocator<float> > > > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for boost::python::detail::container_element<std::vector<std::vector<float, std::allocator<float> >, std::allocator<std::vector<float, std::allocator<float> > > >, unsigned long, boost::python::detail::final_vector_derived_policies<std::vector<std::vector<float, std::allocator<float> >, std::allocator<std::vector<float, std::allocator<float> > > >, false> > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for std::vector<std::vector<double, std::allocator<double> >, std::allocator<std::vector<double, std::allocator<double> > > > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for boost::python::detail::container_element<std::vector<std::vector<double, std::allocator<double> >, std::allocator<std::vector<double, std::allocator<double> > > >, unsigned long, boost::python::detail::final_vector_derived_policies<std::vector<std::vector<double, std::allocator<double> >, std::allocator<std::vector<double, std::allocator<double> > > >, false> > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for std::vector<std::vector<std::complex<double>, std::allocator<std::complex<double> > >, std::allocator<std::vector<std::complex<double>, std::allocator<std::complex<double> > > > > already registered; second conversion method ignored.

  return f(*args, **kwds)

/home/mpiusr/app/anaconda/3/envs/libra/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: to-Python converter for boost::python::detail::container_element<std::vector<std::vector<std::complex<double>, std::allocator<std::complex<double> > >, std::allocator<std::vector<std::complex<double>, std::allocator<std::complex<double> > > > >, unsigned long, boost::python::detail::final_vector_derived_policies<std::vector<std::vector<std::complex<double>, std::allocator<std::complex<double> > >, std::allocator<std::vector<std::complex<double>, std::allocator<std::complex<double> > > > >, false> > already registered; second conversion method ignored.

  return f(*args, **kwds)

Traceback (most recent call last):

  File "run_test.py", line 23, in <module>

    from libra_py import *

AttributeError: module 'libra_py' has no attribute 'Gaussian_methods'

I would greatly appreciate your assistance in resolving these issues.

@WeiLiweili
Copy link
Contributor

WeiLiweili commented Feb 5, 2024 via email

@alexvakimov
Copy link
Member

Thank you, @WeiLiweili . This is a good catch - I have removed the Gaussian_methods from the init.py file of the libra_py folder.
But yes - this is mainly because we moved some files around recently

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants