drjuls / AMBiT

GNU General Public License v3.0
32 stars 15 forks source link

segmentation fault running Cr+ example #17

Closed mgrau closed 6 years ago

mgrau commented 6 years ago

When running the Cr+ example from the master branch on a macbook pro, I immediately get a segmentation fault. I'm using g++ 8.1.0, installed via Homebrew along with all required packages.

AMBiT version: v3.0.1 git branch: master 4f1cb6c compiled: Wed May 30 10:15:10 CEST 2018

input:

argc = 31 Documentation/ExampleCalculation/Cr+.input ID=CrII Z=24 -s123 [Lattice] Lattice/NumPoints=1000 Lattice/StartPoint=1.0e-6 Lattice/EndPoint=50.0 [HF] HF/N=23 HF/Configuration=1s2 2s2 2p6 3s2 3p6 : 3d5 [Basis] Basis/--bspline-basis Basis/ValenceBasis=7spdf Basis/FrozenCore=3s2p [CI] CI/LeadingConfigurations=3d5, 3d4 4s1, 3d4 4p1 CI/ElectronExcitations=2 CI/HoleExcitations=0 CI/EvenParityTwoJ=1, 3, 5 CI/NumSolutions=3 [CI/SmallSide] CI/SmallSide/LeadingConfigurations=3d5, 3d4 4s1, 3d4 4p1 CI/SmallSide/ElectronExcitations=1,5spdf, 2, 5spdf CI/SmallSide/HoleExcitations=0 [MBPT] MBPT/Basis=15spdf [Transitions] Transitions/E2/AllBelow=-9.2 Transitions/M1/MatrixElements=1e:0->1e:1, 3e:0->5e:0 Documentation/ExampleCalculation/Cr+.input


Core orbitals: 1s E = -222.448723263 size: (569) 6.265 2s E = -26.8861828091 size: (647) 12.84 3s E = -3.65304653147 size: (699) 17.82 2p E = -22.7381178168 size: (673) 15.28 3p E = -2.40253423197 size: (726) 20.52 2p+ E = -22.4139800076 size: (674) 15.38 3p+ E = -2.36228057124 size: (727) 20.62 3d E = -0.591219307452 size: (803) 28.52 3d+ E = -0.58695822569 size: (804) 28.63 Excited orbitals: 4s E = -0.203846640381 size: (999) 50 5s E = -0.073631428989 size: (999) 50 6s E = -0.0382640649061 size: (999) 50 7s E = -0.0227258227428 size: (999) 50 8s E = -0.00878164195529 size: (999) 50 9s E = 0.0101691639409 size: (999) 50 10s E = 0.0358256736609 size: (999) 50 11s E = 0.063850980038 size: (999) 50 12s E = 0.151428850431 size: (999) 50 13s E = 0.209216562255 size: (999) 50 14s E = 0.449876493128 size: (999) 50 15s E = 1.20331948655 size: (999) 50 4p E = -0.116400004523 size: (999) 50 5p E = -0.0521230284794 size: (999) 50 6p E = -0.0296082407741 size: (999) 50 7p E = -0.0167733660173 size: (999) 50 8p E = -0.001281121385 size: (999) 50 9p E = 0.0193378840776 size: (999) 50 10p E = 0.0468399111342 size: (999) 50 11p E = 0.0812452031163 size: (999) 50 12p E = 0.190811071992 size: (999) 50 13p E = 0.228911808605 size: (999) 50 14p E = 0.567773561873 size: (999) 50 15p E = 1.42642719053 size: (999) 50 4p+ E = -0.115885445035 size: (999) 50 5p+ E = -0.0519670303177 size: (999) 50 6p+ E = -0.0295391563353 size: (999) 50 7p+ E = -0.0167122298298 size: (999) 50 8p+ E = -0.00119783960713 size: (999) 50 9p+ E = 0.0194166355985 size: (999) 50 10p+ E = 0.0470832521148 size: (999) 50 11p+ E = 0.0786540633918 size: (999) 50 12p+ E = 0.183387459974 size: (999) 50 13p+ E = 0.224266103436 size: (999) 50 14p+ E = 0.498688370451 size: (999) 50 15p+ E = 1.21844167093 size: (999) 50 3d E = -0.591219307452 size: (803) 28.52 4d E = -0.0542305646101 size: (999) 50 5d E = -0.0305212657831 size: (999) 50 6d E = -0.0181184733646 size: (999) 50 7d E = -0.00432671885128 size: (999) 50 8d E = 0.0143121657868 size: (999) 50 9d E = 0.0389714129962 size: (999) 50 10d E = 0.0660460321732 size: (999) 50 11d E = 0.131146666998 size: (999) 50 12d E = 0.214841828978 size: (999) 50 13d E = 0.32448639965 size: (999) 50 14d E = 0.740890032871 size: (999) 50 15d E = 1.62675994953 size: (999) 50 3d+ E = -0.58695822569 size: (804) 28.63 4d+ E = -0.0542036879738 size: (999) 50 5d+ E = -0.0305075571041 size: (999) 50 6d+ E = -0.0181071835795 size: (999) 50 7d+ E = -0.00431021604194 size: (999) 50 8d+ E = 0.0143382932004 size: (999) 50 9d+ E = 0.038746778861 size: (999) 50 10d+ E = 0.066185714477 size: (999) 50 11d+ E = 0.123059776068 size: (999) 50 12d+ E = 0.221395542797 size: (999) 50 13d+ E = 0.295435388569 size: (999) 50 14d+ E = 0.656430891255 size: (999) 50 15d+ E = 1.41497480376 size: (999) 50 4f E = -0.0312539328 size: (999) 50 5f E = -0.0193082587043 size: (999) 50 6f E = -0.00763764376199 size: (999) 50 7f E = 0.00852257643331 size: (999) 50 8f E = 0.0294087947373 size: (999) 50 9f E = 0.0561013771186 size: (999) 50 10f E = 0.0882838582649 size: (999) 50 11f E = 0.176991536968 size: (999) 50 12f E = 0.230649635096 size: (999) 50 13f E = 0.392769498115 size: (999) 50 14f E = 0.804031350407 size: (999) 50 15f E = 1.58339203173 size: (999) 50 4f+ E = -0.0312540206071 size: (999) 50 5f+ E = -0.019308360863 size: (999) 50 6f+ E = -0.00763783329213 size: (999) 50 7f+ E = 0.00852156257019 size: (999) 50 8f+ E = 0.0293361560892 size: (999) 50 9f+ E = 0.0562596177528 size: (999) 50 10f+ E = 0.0863628999206 size: (999) 50 11f+ E = 0.166626138526 size: (999) 50 12f+ E = 0.237071997843 size: (999) 50 13f+ E = 0.359502536654 size: (999) 50 14f+ E = 0.723313159669 size: (999) 50 15f+ E = 1.40697227263 size: (999) 50

AMBiT terminated on a segmentation fault. Stacktrace: 0 ambit 0x0000000105541661 _ZL14signal_handleri + 65 1 libobjc.A.dylib 0x00007fff5a04ddb2 objc_personality_v0 + 0 2 libc++abi.dylib 0x00007fff58c180e7 _ZL25default_terminate_handlerv + 197 3 libobjc.A.dylib 0x00007fff5a04feab _ZL15_objc_terminatev + 105 4 libc++abi.dylib 0x00007fff58c337c9 _ZSt11__terminatePFvvE + 8 5 libc++abi.dylib 0x00007fff58c3326f _ZN10cxxabiv1L22exception_cleanup_funcE19_Unwind_Reason_CodeP17_Unwind_Exception + 0 6 libboost_filesystem.dylib 0x000000010599e4aa _ZN5boost10filesystem6detail16create_directoryERKNS0_4pathEPNS_6system10error_codeE + 330 7 ambit 0x000000010557b2b4 _ZN5Ambit18AngularDataLibraryC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE + 228

mgrau commented 6 years ago

with gcc version 7.3.0 there is no segmentation fault there is instead the error "SlaterIntegrals::GetTwoElectronIntegral() failed to find integral" repeated

Number of CSFs = 18540 x 4356SlaterIntegrals::GetTwoElectronIntegral() failed to find integral. R^0 ( 4p+(-3) 3d(-3), 4p+(-3) 3d(-3)): key = 25309900 num_states = 93 SlaterIntegrals::GetTwoElectronIntegral() failed to find integral. R^2 ( 4p+(-3) 3d(-3), 4p+(-3) 3d(-3)): key = 174920302 num_states = 93 SlaterIntegrals::GetTwoElectronIntegral() failed to find integral. R^1 ( 4p+(-3) 3d(-3), 3d(-3) 4p+(-3)): key = 100116205 num_states = 93 SlaterIntegrals::GetTwoElectronIntegral() failed to find integral.

This also occurs on my linux workstation

drjuls commented 6 years ago

Hi Matt, Thanks for giving AMBiT a try. Clearly we have a couple of teething issues. Regarding gcc-8 on osx/homebrew, I believe the problem is that boost has been built with either gcc-7 or native clang. Boost has to be built using the same compiler as ambit. You can force homebrew to build boost for a particular compiler using the --cc flag, for example: brew install boost --cc=gcc-8.

Also I introduced a bug at the last minute which led to the errors you reported; it is being fixed.

Cheers, Julian

emilyviolet commented 6 years ago

Hi Matt and Julian, I just pushed a patch to master which resolves the errors you reported; if you pull in the latest changes you should be good to go. I'm also going to add a section to the installation guide about the conflicting compilers and Boost, since this is a non-obvious pitfall.

I think we should be good to call this one resolved. Thanks again for the feedback.

Cheers, Emily