You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following is an archived message from the BART-user mailing list, which has now closed.
From: wd***@as*** (William Cochran)
Date: Mon, 12 Dec 2016 16:41:44 -0600 (CST)
Subject: [BART-user] experience installing and testing BART
Hello everyone:
I am working with an undergraduate student here at UT, Arjun
Vijaywargiya. Arjun is interested in spectra of exoplanet
atmospheres, and we thought that we might install BART for
his use.
We seem to have be***@le***artially successful, but still
have a few issues which may call for suggestions from a guru.
First, let me describe my computer system configuration
and what we had to do in the install:
My configuration:
Red Hat Enterprise Linux Server release 5.11 (Tikanga)
gcc version 4.1.2 20080704 (Red Hat 4.1.2-55)
Note that I also run tcsh, not bash
First, I set up an anaconda environment to give the proper version
of python and the needed python packages:
[if in bash]
source activate envBART
[if in tcsh]
source .cshrc
setenv PATH ~/envs/envBART/bin:$PATH
cd BART
installing transit:
I have a different version of gcc than was assumed, and it did
not recognize the -Wno-unused-result flag. Since this refers
to a warning only, I decided to delete the flag and forge ahead:
I then edited those files to comment out the -Wno-unused-result flag
Then we needed to tell the C compiler where to find the include
file numpy/arrayobject.h. I can either execute this line,
or put it in my .cshrc
setenv CPATH /home/syrah/wdc/envs/envBART/lib/python2.7/site-packages/numpy/core/include/
Those who prefer to use bash should execute an equivalent bash command.
cd modules/transit/
make
This gave a few error messages:
In file included from test/test.c:114:
./test/include/test.h:278:26: warning: no ne***@en***f file
test/test.c:127:2: warning: no ne***@en***f file
Compiling test/test_slantpath.o.
test/test_slantpath.c:567:7: warning: no ne***@en***f file
Building executable "transit".
Building python extension.
python/transit_wrap.c: In function ‘SWIG_Python_ConvertFunctionPtr’:
python/transit_wrap.c:2034: warning: initialization discards qualifiers from pointer target type
python/transit_wrap.c: At top level:
python/transit_wrap.c:2296: warning: function declaration isn’t a prototype
python/transit_wrap.c:3744: warning: function declaration isn’t a prototype
python/transit_wrap.c: In function ‘SWIG_Python_FixMethods’:
python/transit_wrap.c:3789: warning: initialization discards qualifiers from pointer target type
Installing BART:
same as for transit regarding:
-Wno-unused-result
it then seemed to work with the same few minor warnings:
Building python extension.
python/transit_wrap.c: In function ‘SWIG_Python_ConvertFunctionPtr’:
python/transit_wrap.c:2034: warning: initialization discards qualifiers from pointer target type
python/transit_wrap.c: At top level:
python/transit_wrap.c:2296: warning: function declaration isn’t a prototype
python/transit_wrap.c:3744: warning: function declaration isn’t a prototype
python/transit_wrap.c: In function ‘SWIG_Python_FixMethods’:
python/transit_wrap.c:3789: warning: initialization discards qualifiers from pointer target type
So we then went to try some of the examples.
First, the "Quick Example" in BART Users Manual Section 4:
$topdir/BART/modules/transit/pylineread/src/pylineread.py -c pyline_demo.cfg
appears to work OK. It finishes with:
Sort time: 0.494 seconds
Transitions per isotope:
[107079 12911 29492]
Writing 149482 transition lines.
Packing time: 0.112 seconds
Writing time: 0.018 seconds
Done.
and it produces the file CH4_HITRAN_2-4um.tli.
Then the
$topdir/BART/modules/transit/transit/transit -c transit_demo.cfg --justOpacity
grinds away for a while, spewing lots of output to the screen.
It appears to end normally and generates a file opacity_CH4.dat.
Then, the manual says to
cp $topdir/BART/examples/demo/BART.cfg .
But $topdir/BART/examples/demo/ has no 'BART.cfg'. It has:
BART_eclipse.cfg BART_transit.cfg pyline_demo.cfg transit_demo.cfg
Taking a wild guess to use BART_transit.cfg,
$topdir/BART/BART.py -c BART_transit.cfg
It then gave a lot of output, and started counting down iterations...
workstation load average leveled out at 11 (which is not great,
since the machine has only 4 cores....)
Then, we got:
...
Iteration: 05001
Iteration: 05000
Iteration: 04999
[::::: ] 50.0% completed (Mon Dec 12 16:30:17 2016)
Out-of-bound Trials:
[10762 9816 10671 0 0]
Best Parameters: (chisq=0.0039)
[ -1.87282452e+00 -7.86566750e-02 1.00000000e+00 0.00000000e+00
8.90019582e-01 9.65086783e+04 -1.00103963e+00]
Gelman-Rubin statistic for free parameters:
[ 1.00118807 1.00136093 1.00574359 1.00770341 1.00272216]
All parameters have converged to within 1% of unity.
Fin, MCMC Summary:
------------------
Burned in iterations per chain: 500
Number of iterations per chain: 5000
MCMC sample size: 45000
Acceptance rate: 27.75%
Best-fit params Uncertainties S/N Sample Mean Note
-1.8728245e+00 1.1418319e+00 1.64 -3.0425095e+00
-7.8656675e-02 8.1628676e-01 0.10 -4.0369551e-01
1.0000000e+00 0.0 --- --- Fixed
0.0000000e+00 0.0 --- --- Fixed
8.9001958e-01 1.8276982e-01 4.87 8.5962827e-01
9.6508678e+04 1.1515751e+02 838.06 9.6526997e+04
-1.0010396e+00 2.0831719e-01 4.81 -9.5696444e-01
Best-parameter's chi-squared: 0.0039
Bayesian Information Criterion: 11.5169
Reduced chi-squared: 0.0008
Standard deviation of residuals: 8.58017e-07
Plotting figures ...
QXcbConnection: Failed to initialize XRandr
FUNC FLAG 99: func out
FUNC FLAG OUT ~~ 100 ~~
Transit call with the best-fitting values.
/data1/kepler/UCF_BART/BART/code/makeatm.py:416: FutureWarning: elementwise
comparison failed; returning scalar instead, but in the future will perform
elementwise comparison
if stoich_info == [[]]:
/data1/kepler/UCF_BART/BART/code/bestFit.py:186: VisibleDeprecationWarning:
using a non-integer number instead of an integer will result in an error in
the future
abundances[columns[i]-3] = abundances[columns[i]-3] * 10**abun_fact[i]
/data1/kepler/UCF_BART/BART/code/bestFit.py:356: VisibleDeprecationWarning:
using a non-integer number instead of an integer will result in an error in
the future
data_stack = data[0,:,burnin:]
/data1/kepler/UCF_BART/BART/code/bestFit.py:358: VisibleDeprecationWarning:
using a non-integer number instead of an integer will result in an error in
the future
data_stack = np.hstack((data_stack, data[c, :, burnin:]))
Plotting MCMC PT profile figure.
--------------------------------------------------
TRANSIT v4.0
--------------------------------------------------
Plotting BART best-fit modulation spectrum figure.
~~ BART End ~~
...
and it produced a several .png files and BART_demo_transit_spectrum.dat,
bestFit.atm, bestFit_tconfig.cfg, band_eclipse.npy, MCMC.log, output.npy.
So, I guess it worked?
The trying Example 5.1 in the BART manual: WASP-12b
1)H2O, CO2, CO, CH4 scripts were successfully downloaded from the server
and extracted in the directory.
2)The pylineread configuration file was copied over. Pylineread ran
successfully and a transition-line-information file was created.
3)Transition Exoplanet file was copied over. Stellar Kurucz file was
downloaded.
4)BART configuration file was copied, and BART was run.
5)The code successfully ran and created a table of opacities. Everything
worked fine until it reached the MCMC part.
6)Soon after the MCMC part was reached, the following error was encountered
Error in module: 'mcmc.py', function: 'mcmc', line: 184
One or more of the initial-guess values:
[[-0.5 -0.2 1. 0. 1.1 -5. 2. 2. -1. ]]
are greater than their higher boundaries:
[ 1. 2. 0. 1. 1.2 1.5 7. 1.5 1.5]
Followed by a traceback.
And then it all just hung.
The error message is probably related to the following lines (97:103)
in WASP-12b/BART.cfg:
The model fitting parameters:
The 'Mi' parameters are the log10 of an abundance scale factor:
So this is probably also a question of which configuration file
is really appropriate for this example? I guess we used the
wrong one?
Feedback, comments and suggestions would be very welcome!
Cheers,
Bill
William Cochran wd***@as***
Research Professor wd***@ma***
The University of Te***@au*** +1 512-471-6474
Department of Astronomy fax +1 512-471-6016
2515 Speedway, Stop C1400
Austin, Texas 78712-1205
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
The following is an archived message from the BART-user mailing list, which has now closed.
From: wd***@as*** (William Cochran)
Date: Mon, 12 Dec 2016 16:41:44 -0600 (CST)
Subject: [BART-user] experience installing and testing BART
Hello everyone:
I am working with an undergraduate student here at UT, Arjun
Vijaywargiya. Arjun is interested in spectra of exoplanet
atmospheres, and we thought that we might install BART for
his use.
We seem to have be***@le***artially successful, but still
have a few issues which may call for suggestions from a guru.
First, let me describe my computer system configuration
and what we had to do in the install:
My configuration:
Red Hat Enterprise Linux Server release 5.11 (Tikanga)
gcc version 4.1.2 20080704 (Red Hat 4.1.2-55)
Note that I also run tcsh, not bash
First, I set up an anaconda environment to give the proper version
of python and the needed python packages:
echo $PATH
setenv PATH [proper path to]/anaconda/bin:$PATH
echo $PATH
conda create -n envBART python=2.7 Numpy SciPy matplotlib mpi4py SymPy setuptools
[if in bash]
source activate envBART
[if in tcsh]
source .cshrc
setenv PATH ~/envs/envBART/bin:$PATH
cd BART
installing transit:
I have a different version of gcc than was assumed, and it did
not recognize the -Wno-unused-result flag. Since this refers
to a warning only, I decided to delete the flag and forge ahead:
find . -name Makefile -exec grep -H Wno-unused-result {} ;
I then edited those files to comment out the -Wno-unused-result flag
Then we needed to tell the C compiler where to find the include
file numpy/arrayobject.h. I can either execute this line,
or put it in my .cshrc
setenv CPATH /home/syrah/wdc/envs/envBART/lib/python2.7/site-packages/numpy/core/include/
Those who prefer to use bash should execute an equivalent bash command.
cd modules/transit/
make
This gave a few error messages:
Installing BART:
same as for transit regarding:
-Wno-unused-result
it then seemed to work with the same few minor warnings:
Building python extension.
python/transit_wrap.c: In function ‘SWIG_Python_ConvertFunctionPtr’:
python/transit_wrap.c:2034: warning: initialization discards qualifiers from pointer target type
python/transit_wrap.c: At top level:
python/transit_wrap.c:2296: warning: function declaration isn’t a prototype
python/transit_wrap.c:3744: warning: function declaration isn’t a prototype
python/transit_wrap.c: In function ‘SWIG_Python_FixMethods’:
python/transit_wrap.c:3789: warning: initialization discards qualifiers from pointer target type
So we then went to try some of the examples.
First, the "Quick Example" in BART Users Manual Section 4:
$topdir/BART/modules/transit/pylineread/src/pylineread.py -c pyline_demo.cfg
appears to work OK. It finishes with:
Sort time: 0.494 seconds
Transitions per isotope:
[107079 12911 29492]
Writing 149482 transition lines.
Packing time: 0.112 seconds
Writing time: 0.018 seconds
Done.
and it produces the file CH4_HITRAN_2-4um.tli.
Then the
$topdir/BART/modules/transit/transit/transit -c transit_demo.cfg --justOpacity
grinds away for a while, spewing lots of output to the screen.
It appears to end normally and generates a file opacity_CH4.dat.
Then, the manual says to
cp $topdir/BART/examples/demo/BART.cfg .
But $topdir/BART/examples/demo/ has no 'BART.cfg'. It has:
BART_eclipse.cfg BART_transit.cfg pyline_demo.cfg transit_demo.cfg
Taking a wild guess to use BART_transit.cfg,
$topdir/BART/BART.py -c BART_transit.cfg
It then gave a lot of output, and started counting down iterations...
workstation load average leveled out at 11 (which is not great,
since the machine has only 4 cores....)
Then, we got:
...
Iteration: 05001
Iteration: 05000
Iteration: 04999
...
and it produced a several .png files and BART_demo_transit_spectrum.dat,
bestFit.atm, bestFit_tconfig.cfg, band_eclipse.npy, MCMC.log, output.npy.
So, I guess it worked?
The trying Example 5.1 in the BART manual: WASP-12b
1)H2O, CO2, CO, CH4 scripts were successfully downloaded from the server
and extracted in the directory.
2)The pylineread configuration file was copied over. Pylineread ran
successfully and a transition-line-information file was created.
3)Transition Exoplanet file was copied over. Stellar Kurucz file was
downloaded.
4)BART configuration file was copied, and BART was run.
5)The code successfully ran and created a table of opacities. Everything
worked fine until it reached the MCMC part.
6)Soon after the MCMC part was reached, the following error was encountered
Followed by a traceback.
And then it all just hung.
The error message is probably related to the following lines (97:103)
in WASP-12b/BART.cfg:
The model fitting parameters:
The 'Mi' parameters are the log10 of an abundance scale factor:
log(kappa) log(g1) log(g2) alpha beta log(M1) log(M2) ...
params = -0.5 -0.2 1.0 0.0 1.1 -5.0 2.0 -2.0 -1.0
pmin = -5.0 -2.0 -2.0 0.0 0.55 -11.0 -2.0 -9.0 -9.0
pmax = 1.0 2.0 0.0 1.0 1.2 1.5 7.0 1.5 1.5
stepsize = 0.01 0.01 0.0 0.0 0.001 0.1 0.1 0.1 0.1
So this is probably also a question of which configuration file
is really appropriate for this example? I guess we used the
wrong one?
Feedback, comments and suggestions would be very welcome!
Cheers,
Bill
William Cochran wd***@as***
Research Professor wd***@ma***
The University of Te***@au*** +1 512-471-6474
Department of Astronomy fax +1 512-471-6016
2515 Speedway, Stop C1400
Austin, Texas 78712-1205
Beta Was this translation helpful? Give feedback.
All reactions