ranganathanlab / bmDCA

Fork of matteofigliuzzi/bmDCA repository for Boltzmann-machine Direct Coupling Analysis (bmDCA).
GNU General Public License v3.0
33 stars 12 forks source link

installation issue on ubuntu #5

Closed madani-sf closed 4 years ago

madani-sf commented 4 years ago

I'm attempting to install on a GCP pod running ubuntu 16.04. I've installed all the latest dependencies with no issues. I can run ./autogen.sh --prefix=/usr/local but when running make -j4 , i encounter the following error

~/bmDCA# make -j4
Making all in src
make[1]: Entering directory '/root/bmDCA/src'
  CXX      bmdca.o
  CXX      model.o
  CXX      msa.o
  CXX      msa_stats.o
  CXX      run.o
  CXX      mcmc.o
  CXX      mcmc_stats.o
  CXX      graph.o
mcmc_stats.cpp: In member function 'void MCMCStats::computeSampleStats()':
mcmc_stats.cpp:296:31: error: no matching function for call to 'sum(arma::Cube<double>&, int)'
         n2av = arma::sum(n2, 0) / (M * reps);
                               ^
In file included from /usr/include/armadillo:397:0,
                 from mcmc_stats.hpp:4,
                 from mcmc_stats.cpp:1:

...

/usr/include/armadillo_bits/fn_sum.hpp:177:1: note:   template argument deduction/substitution failed:
mcmc_stats.cpp:297:50: note:   'const arma::eOpCube<arma::Cube<double>, arma::eop_pow' is not derived from 'const arma::SpOp<T1, arma::spop_sum>'
         n2squared = arma::sum(arma::pow(n2, 2), 0) / (M * reps);
                                                  ^
Makefile:428: recipe for target 'mcmc_stats.o' failed
make[1]: *** [mcmc_stats.o] Error 1
make[1]: *** Waiting for unfinished jobs....
run.cpp: In constructor 'Sim::Sim(MSAStats, std::__cxx11::string, std::__cxx11::string, bool)':
run.cpp:383:28: warning: ignoring return value of 'int chdir(const char*)', declared with attribute warn_unused_result [-Wunused-result]
     chdir(dest_dir.c_str());
                            ^
make[1]: Leaving directory '/root/bmDCA/src'
Makefile:362: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

I'm able to install and run perfectly on macOS, but not ubuntu. Tried tinkering with armadillo to no avail. Any guidance?

madani-sf commented 4 years ago

seemed to be an issue with compilers

kylemeador commented 3 years ago

I just ran into this issue as well. Could you elaborate on the fix?