Comments (24)
Can you try removing this line
https://github.com/NNPDF/apfelcomb/blob/master/Makefile.inc#L8
from the Makefile?
from apfelcomb.
and try again after make clean
.
from apfelcomb.
Hi Zahari,
thanks! It works now!
A question about its usage. If I want to get predictions for BCDMSD, I do that, but it seems unable to find database. What am I doing wrong?
`mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ ./apfel_comb dis 79 53
███╗ ██╗███╗ ██╗██████╗ ██████╗ ███████╗
████╗ ██║████╗ ██║██╔══██╗██╔══██╗██╔════╝
██╔██╗ ██║██╔██╗ ██║██████╔╝██║ ██║█████╗
██║╚██╗██║██║╚██╗██║██╔═══╝ ██║ ██║██╔══╝
██║ ╚████║██║ ╚████║██║ ██████╔╝██║
╚═╝ ╚═══╝╚═╝ ╚═══╝╚═╝ ╚═════╝ ╚═╝ 2012-2015
ver : 1.2.0b5, coredevs : N.H., S.C.
APFELcomb
terminate called after throwing an instance of 'NNPDF::FileError'
what(): [IndexDB::IndexDB] error: Can't open database: unable to open database file
Aborted (core dumped)
`
from apfelcomb.
Maybe @nhartland can help here?
Btw, as discussed I think it might be beneficial to have a more robust solution for the makefile.
from apfelcomb.
@mariaubiali can you paste here the contents of the db/
directory?
@Zaharid yeah fair enough, this is the first time someone has actually had a problem with that, but if it is actually causing problems I agree. I'll just remove it, it only causes a problem on hydra.
from apfelcomb.
OK, I guess that - having been away for a while - I need to update everything.
I have cancelled everything I had and then
$ git clone [email protected]:NNPDF/binary-bootstrap.git
$ ./binary-botstrap/bootstrap.sh % miniconda installed in /data/sparticle/mu227/miniconda3
$ conda create -n nnpdf-dev libnnpdf gxx_linux-64y
$ conda install cern-root
$ conda install nnpdf validphys2
$ cd /data/sparticle/mu227/nnpdfgit/external/applgridphoton
$ autoreconf -i
$ ./configure --prefix=/data/sparticle/mu227/miniconda3/envs/nnpdf-dev
$ make
$ make install
So far so good, everything is installed fine. If I remove the line as suggested by Zahari I can also compile apfelcomb.
Then I try that and it does not work
`(nnpdf-dev) mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ ./apfel_comb dis 79 52
███╗ ██╗███╗ ██╗██████╗ ██████╗ ███████╗
████╗ ██║████╗ ██║██╔══██╗██╔══██╗██╔════╝
██╔██╗ ██║██╔██╗ ██║██████╔╝██║ ██║█████╗
██║╚██╗██║██║╚██╗██║██╔═══╝ ██║ ██║██╔══╝
██║ ╚████║██║ ╚████║██║ ██████╔╝██║
╚═╝ ╚═══╝╚═╝ ╚═══╝╚═╝ ╚═════╝ ╚═╝ 2012-2015
ver : 1.2.0b5, coredevs : N.H., S.C.
APFELcomb
terminate called after throwing an instance of 'NNPDF::RuntimeException'
what(): [dbquery] error: SQLITE Error: no such column: global_nx
Aborted (core dumped)
`
A possible problem is that what is in nnpdfgit/nnpdf/nnpdfcpp/data
(nnpdf-dev) mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ ls ../nnpdf/nnpdfcpp/data/ commondata disp_theory.py NLOCFAC NNLOCFAC theory.db
is not what is in /miniconda3/envs/nnpdf-dev/share/NNPDF/data/
(nnpdf-dev) mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ ls /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/share/NNPDF/data/ commondata disp_theory.py doc NLOCFAC NNLOCFAC __pycache__ tartheory.sh theory_52 theory.db theorydb.sql upload_theory.sh
Shall I just link symbolically the miniconda diretory into the nnpdfcpp one?
Sorry about the confusion
from apfelcomb.
Yeah, that's an error suggesting that APFELcomb is finding an old theory database. It should be using the one from miniconda though, which should be up to date. What does
pkg-config nnpdf --cflags
return for you?
from apfelcomb.
@mariaubiali Please don't install libnnpdf
. That is very old and predates the merging of the code. Use nnpdf
instead.
from apfelcomb.
@Zaharid OK I have reinstalled everything using only nnpdf
@nhartland If I do that I get the one in miniconda
mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ pkg-config nnpdf --cflags
-I/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include
but still have the same error
``
mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ ./apfel_comb dis 79 52
███╗ ██╗███╗ ██╗██████╗ ██████╗ ███████╗
████╗ ██║████╗ ██║██╔══██╗██╔══██╗██╔════╝
██╔██╗ ██║██╔██╗ ██║██████╔╝██║ ██║█████╗
██║╚██╗██║██║╚██╗██║██╔═══╝ ██║ ██║██╔══╝
██║ ╚████║██║ ╚████║██║ ██████╔╝██║
╚═╝ ╚═══╝╚═╝ ╚═══╝╚═╝ ╚═════╝ ╚═╝ 2012-2015
ver : 1.2.0b5, coredevs : N.H., S.C.
APFELcomb
terminate called after throwing an instance of 'NNPDF::RuntimeException'
what(): [dbquery] error: SQLITE Error: no such column: global_nx
Aborted (core dumped)
``
from apfelcomb.
@nhartland the line where the code seems to crash is
Splash(); QCD::qcd_param par; QCD::parse_input(iTh, par);
from apfelcomb.
@Zaharid
Indeed, the problems seems that the theory.db in miniconda is different from the theory.db in nnpdfcpp/
mu227@consist:/data/sparticle/mu22 ... nvs/nnpdf-dev/share/NNPDF/data $ sqldiff theory.db /data/sparticle/mu227/nnpdfgit/nnpdf/nnpdfcpp/data/theory.db ALTER TABLE TheoryIndex ADD COLUMN global_nx; UPDATE TheoryIndex SET global_nx=0 WHERE ID=1; UPDATE TheoryIndex SET global_nx=0 WHERE ID=2; [..]
Which one is the correct one? Why are they different? Can this be fixed?
from apfelcomb.
What nnpdfcpp are you referring to? Is it is the repository, then that shouldn't be used any more, because it is all merged into nnpdf. If it is the folder inside the nnpdf repository, then the theory db in conda must be exactly the same as that in the master branch, with the most up to date package.
from apfelcomb.
Hi Zahari,
I don't know what happened but the fact is that if I copy the theory.db file into the miniconda envs folder apfelcomb works!
The directory nnpdfgit/nnpdf/nnpdfcpp/data/ is the one that I get when I download the nnpdf git repository
$ cp /data/sparticle/mu227/nnpdfgit/nnpdf/nnpdfcpp/data/theory.db /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/share/NNPDF/data/theory.db
from apfelcomb.
That's a bit weird, are you on a branch or something in your nnpdf/ directory?
If I check out the master, I'm getting the correct theorydb (with the global_nx field).
from apfelcomb.
Hi Zahari,
I have downloaded the master by typing
git clone [email protected]:NNPDF/nnpdf.git
Indeed the theorydb in nnpdf/nnpdfcpp/data/theory.db is fine, it is the one in miniconda that does not seem to be fine!
from apfelcomb.
This is very strange. It is working perfectly for me.
$ conda create -p /tmp/p nnpdf
$ md5sum /tmp/p/share/NNPDF/data/theory.db
d836f323a04486b6284793228bc711fd /tmp/p/share/NNPDF/data/theory.db
$ pwd
/home/zah/nngit/nnpdf/nnpdfcpp/data
$ md5sum theory.db
d836f323a04486b6284793228bc711fd theory.db
$ conda list -p /tmp/p/ nnpdf
# packages in environment at /tmp/p:
#
# Name Version Build Channel
nnpdf 3.2.738+g3e22385 py36hf484d3e_0 https://zigzah.com/static/conda-pkgs-private
from apfelcomb.
The one possibility that occurs to me is that you don't have an up to date conda package. Please compare with the version above.
from apfelcomb.
Hi Zahari
they are not the same and indeed the one in the nnpdf-dev conda environment does not seem to be up-to-date.
$ md5sum /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/share/NNPDF/data/theory.db b24bce44ce0536e1791df890a4840797 /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/share/NNPDF/data/theory.db $ md5sum /data/sparticle/mu227/nnpdfgit/nnpdf/nnpdfcpp/data/theory.db d836f323a04486b6284793228bc711fd /data/sparticle/mu227/nnpdfgit/nnpdf/nnpdfcpp/data/theory.db
It is weird because I have reinstalled conda this morning by doing the followin
$ git clone [email protected]:NNPDF/binary-bootstrap.git $ ./binary-bootstrap/bootstrap.sh $ conda create -n nnpdf-dev nnpdf gxx_linux-64 $ conda activate nnpdf-dev $ conda install cern-root $ (conda install validphys)
d836f323a04486b6284793228bc711fd
from apfelcomb.
Is this linux or mac? What happens when you try
conda update nnpdf
from apfelcomb.
It is linux
If I update I get
`(nnpdf-dev) mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ conda update nnpdfSolving environment: done
All requested packages already installed.
`
from apfelcomb.
Weird. You say you uninstalled libnnpdf or started over today? It must be finding that there are conflicting packages but it doesn't make sense. And just worked for me.
What happens with:
conda install nnpdf=3.2.738
from apfelcomb.
OK, I have to go now, but I have installed that version of nnpdf, now the theory.db is fine but apfelcomb does no longer compile...
(nnpdf-dev) mu227@consist:/data/sparticle/mu227/nnpdfgit/apfelcomb $ make clean && make
rm -f -f apfel_comb src/cfac_scale appl_optgrid ftdy_hcx
make[1]: Entering directory '/data/sparticle/mu227/nnpdfgit/apfelcomb/src/core'
rm -f -f fk_appl.o fk_dis.o fk_qcd.o fk_utils.o fk_grids.o fk_ftdy.o ../libac_core.a
make[1]: Leaving directory '/data/sparticle/mu227/nnpdfgit/apfelcomb/src/core'
make[1]: Entering directory '/data/sparticle/mu227/nnpdfgit/apfelcomb/src/core'
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/bin/x86_64-conda_cos6-linux-gnu-c++ -Wall -O3 -D RESULTS_PATH="./results/" -D APPL_PATH="../applgrids/" -D DB_PATH="./db/" -I/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include -I/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include -pthread -std=c++1z -m64 -I/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include -I/data/sparticle/mu227/nnpdfgit/apfel/installation/include -std=c++14 -I/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include -I/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include -I .. -DNDEBUG -D_FORTIFY_SOURCE=2 -O2 -c -o fk_appl.o fk_appl.cc
In file included from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/x86_64-conda_cos6-linux-gnu/include/c++/7.2.0/string_view:39:0,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/RStringView.h:19,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:28,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TNamed.h:26,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TAxis.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1D.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/appl_grid/appl_grid.h:32,
from ../apfelcomb/fk_appl.h:19,
from fk_appl.cc:5:
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/x86_64-conda_cos6-linux-gnu/include/c++/7.2.0/bits/c++17_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2017 standard. This support must be enabled with the -std=c++17 or -std=gnu++17 compiler options.
#error This file requires compiler and library support \
^~~~~
In file included from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:28:0,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TNamed.h:26,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TAxis.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1D.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/appl_grid/appl_grid.h:32,
from ../apfelcomb/fk_appl.h:19,
from fk_appl.cc:5:
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/RStringView.h:67:17: error: expected type-specifier
operator std::string_view() const { return std::string_view(fData,fLength); }
^~~
In file included from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TNamed.h:26:0,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TAxis.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1D.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/appl_grid/appl_grid.h:32,
from ../apfelcomb/fk_appl.h:19,
from fk_appl.cc:5:
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:104:13: error: expected type-specifier
operator std::string_view() const { return std::string_view(Data(),fExtent); }
^~~
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:257:23: error: 'string_view' in namespace 'std' does not name a type
TString(const std::string_view &sub);
^~~~~~~~~~~
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:293:37: error: 'string_view' in namespace 'std' does not name a type
TString &operator=(const std::string_view &s);
^~~~~~~~~~~
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:420:9: error: 'string_view' in namespace 'std' does not name a type
std::string_view View() const { return std::string_view(GetPointer(),Length()); }
^~~~~~~~~~~
In file included from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TNamed.h:26:0,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TAxis.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TH1D.h:24,
from /data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/appl_grid/appl_grid.h:32,
from ../apfelcomb/fk_appl.h:19,
from fk_appl.cc:5:
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:785:53: error: 'string_view' in namespace 'std' does not name a type
inline Bool_t operator==(const char *s1, const std::string_view &s2)
^~~~~~~~~~~
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:785:68: error: 'Bool_t operator==(const char*, const int&)' must have an argument of class or enumerated type
inline Bool_t operator==(const char *s1, const std::string_view &s2)
^
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:790:37: error: 'string_view' in namespace 'std' does not name a type
inline Bool_t operator==(const std::string_view &s1, const char *s2)
^~~~~~~~~~~
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:790:68: error: 'Bool_t operator==(const int&, const char*)' must have an argument of class or enumerated type
inline Bool_t operator==(const std::string_view &s1, const char *s2)
^
/data/sparticle/mu227/miniconda3/envs/nnpdf-dev/include/TString.h:803:37: error: 'string_view' in namespace 'std' does not name a type
std::string printValue(const std::string_view* val);
^~~~~~~~~~~
<builtin>: recipe for target 'fk_appl.o' failed
make[1]: *** [fk_appl.o] Error 1
make[1]: Leaving directory '/data/sparticle/mu227/nnpdfgit/apfelcomb/src/core'
Makefile:16: recipe for target 'core' failed
make: *** [core] Error 2
from apfelcomb.
Right. I needed to compile root with c++17 and the things that include it must be c++17 as well. This can be done adding the corresponding flag in the makefile:
--- a/Makefile.inc
+++ b/Makefile.inc
@@ -5,7 +5,6 @@
################################################################################
-CXX = g++
SHELL=/bin/bash
# APPLCOMB paths
@@ -43,4 +42,4 @@ GSLLIBS=$(shell gsl-config --libs)
PRJLDFLAGS = $(LHAPDFLIBS) $(APPLCLIBS) $(ROOTLIBS) $(APFELLIBS) $(NNPDFLIBS) $(GSLLIBS) -lsqlite3
# scheduling and optimization options (such as -DSSE -DSSE2 -DP4)
-PRJCXXFLAGS = -Wall -O3 $(ALLDIR) $(LHAPDFINCS) $(APPLINCS) $(ROOTINCS) $(APFELINCS) $(NNPDFINCLUDE) $(GSLINCLUDE)
+PRJCXXFLAGS = -Wall -O3 $(ALLDIR) $(LHAPDFINCS) $(APPLINCS) $(ROOTINCS) $(APFELINCS) $(NNPDFINCLUDE) $(GSLINCLUDE) -std=c++17
from apfelcomb.
Thank you Zahari, it work now!
from apfelcomb.
Related Issues (20)
- Compilation error in APFELcomb HOT 31
- Segmentation fault trigerred by APFEL HOT 54
- Problem using FKtables HOT 2
- Error in exporting FK table HOT 5
- Error in compilation of applgridphoton (needed to install APFELcomb) HOT 7
- Problem on hydra
- Remove references to the c++ standard HOT 1
- Problems running: "no such column: global_nx" HOT 9
- SIA FK tables in the new apfelcomb layout
- Segmentation fault -- Error in <TCling::RegisterModule> HOT 12
- Generate Evolution Tables HOT 1
- Mismatched names and underscores HOT 6
- make dev not working HOT 8
- Apfelcomb does not compile with APFEL master HOT 5
- *** stack smashing detected *** HOT 4
- Segmentation fault running apfelcomb HOT 7
- New Error running APFELcomb: too many steps! HOT 1
- possible error in the computations of DIS FKtables
- Where to obtain applgrid-1.4.70-nnpdf?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apfelcomb.