get travis-ci to build and run models
Enforce a common structure to the examples.
Use travis-ci to run models with a ___ in each directory.
___ is to be defined.
I am currently working on a package to structure examples. I had played around with travisci, and it has great support for package, out of the box.
I suggest to make examples to package: in inst/extdata/vol1/rats etc, I keep the raw stan and data.R files with the same structure as before. All R-test files will be written as vignettes; these are automatically tested by travis build, and provide nice documentation.
If someone wants to play with the code, the vignettes can be run separately, no global rebuild needed.
You can put makefiles into the inst/extadata/volx files; those currently available do not run, and I gave up when trying to understand the directory structure, which is surprisingly different between the CmdStan installer and Github clone. Maybe you could provide one working example. I know that Bob want standalone tests.
So for pure CmdStan testing, a top level makefile refering to the sub-makefiles could be added. I will make a separate github repository tomorrow so you can check the concept.
(Corrected: should be packages, not projects as had been written)
That would be great! I couldn't follow everything you said, but if you have an idea of an implementation, that's better than what I've got.
On Wed, Aug 12, 2015 at 11:30 AM, Dieter Menne [email protected] wrote:
I am currently working on a project to structure examples. I had played around with travisci, and it has great support for projects, out of the box. I suggest to make examples to projects: in inst/extdata/vol1/rats etc, I keep the raw stan and data.R files with the same structure as before. All R-test files will be written as vignettes; these are automatically tested by travis build, and provide nice documentation.
If someone wants to play with the code, the vignettes can be run separately, no global rebuild needed.
You can put makefiles into the inst/extadata/volx files; those currently available do not run, and I gave up when trying to understand the directory structure, which is surprisingly different between the CmdStan installer and Github clone. Maybe you could provide one working example.
So for pure CmdStan testing, a top level makefile refering to the sub-makefiles could be added. I will make a separate github repository tomorrow so you can check the concept.
— Reply to this email directly or view it on GitHub https://github.com/stan-dev/example-models/issues/26#issuecomment-130343407 .
See https://github.com/dmenne/bugsexamples and http://menne-biomed.de/uni/rats.html for a sample output vignette. Yaml not yet done, but hopefully coming soon. The CmdStan version is your homework assigment .-)
https://travis-ci.org/dmenne/bugsexamples/builds
Working on yaml/rstan. This sometimes works, sometimes there is an error during rstan install. In one case vignette build (=lot of rstan) finished with ok, but there was an internal error not caught as such by Travis. Running with multiple chains and/or cpu has been switched off.
I suspect there is some sort of timeout going on. Any other examples of vignette rstan builds around?
I have written a minimal test package for TravisCI and running vignette build; see
https://travis-ci.org/dmenne/rstanyaml/builds/75600644
Build of rstan stops at line 1566.
Out of memory as reported by many others. clang to the rescue?
https://github.com/travis-ci/travis-ci/issues/1972
Looks like Travis open source version cannot handle rstan complexity. Too bad. Will give up.
lang__grammars__statement_2_grammar_inst.o
g++ -I/usr/share/R/include -DNDEBUG -I"../inst/include" -I"../inst/include/boost_not_in_BH" -I"`"/usr/lib/R/bin/Rscript" -e "cat(system.file('include', 'src', package = 'StanHeaders'))"`" -DBOOST_RESULT_OF_USE_TR1 -DBOOST_NO_DECLTYPE -DBOOST_DISABLE_ASSERTS -I"/usr/local/lib/R/site-library/Rcpp/include" -I"/usr/local/lib/R/site-library/RcppEigen/include" -I"/usr/local/lib/R/site-library/BH/include" -I"/usr/local/lib/R/site-library/StanHeaders/include" -fpic -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -D_FORTIFY_SOURCE=2 -g -c lang__grammars__statement_grammar_inst.cpp -o lang__grammars__statement_grammar_inst.o
g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-4.6/README.Bugs> for instructions.
make: *** [lang__grammars__statement_grammar_inst.o] Error 4
ERROR: compilation failed for package ‘rstan’