coatless-rpkg / rcppensmallen Goto Github PK
View Code? Open in Web Editor NEWRcpp integration for the Ensmallen templated C++ mathematical optimization library
Home Page: http://r-pkg.thecoatlessprofessor.com/rcppensmallen/
Rcpp integration for the Ensmallen templated C++ mathematical optimization library
Home Page: http://r-pkg.thecoatlessprofessor.com/rcppensmallen/
Maybe I don't understand the plugin system, but shouldn't inlineCxxPlugin
be exported in order for other packages to use it?
In PR #25's 29ed79b , we lost the ability to fully link to the Ensmallen commits on GitHub due to the NEWS.md
file having too many links to pages on GitHub. e.g.
From: NEWS.md
Status: 429
Message: Too Many Requests
From Slack, @eddelbuettel mentioned that Kurt Hornik is working to add a GITHUB_PAT
/GITHUB_TOKEN
to allow for increased traffic rates to GitHub. Once this goes through, we can restore by running:
# Read in news items
items = readLines("NEWS.md")
# Convert
items = sub(
"mlpack/ensmallen#([0-9]+)",
"[#\1](https://github.com/mlpack/ensmallen/pulls/\1)",
items
)
# Write out fixed items
writeLines(items, "NEWS.md")
In all that exitement about GH Actions it seems to have been overlooked that the most current R version is not 3.6 anymore.
Hi, while installing the package I got the following error messages
installing source package ‘RcppEnsmallen’ ...
** package ‘RcppEnsmallen’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
/opt/local/bin/clang++-mp-13 -std=gnu++11 -I"/opt/local/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I'/Users/gpasa/Library/R/x86_64/4.1/library/Rcpp/include' -I'/Users/gpasa/Library/R/x86_64/4.1/library/RcppArmadillo/include' -I/opt/local/include -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk -I../inst/include -fopenmp -fPIC -pipe -Os -stdlib=libc++ -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk -arch x86_64 -c RcppExports.cpp -o RcppExports.o
In file included from RcppExports.cpp:4:
In file included from ./../inst/include/RcppEnsmallen.h:25:
In file included from ../inst/include/ensmallen.hpp:75:
../inst/include/ensmallen_bits/callbacks/callbacks.hpp:765:26: error: no member named 'HasGenerationalStepTakenSignature' in namespace 'ens::callbacks::traits'
callbacks::traits::HasGenerationalStepTakenSignature<
~~~~~~~~~~~~~~~~~~~^
../inst/include/ensmallen_bits/callbacks/callbacks.hpp:766:7: error: 'CallbackType' does not refer to a value
CallbackType, OptimizerType, FunctionType, MatType, ObjectivesVecType,
^
../inst/include/ensmallen_bits/callbacks/callbacks.hpp:758:21: note: declared here
template<typename CallbackType,
^
../inst/include/ensmallen_bits/callbacks/callbacks.hpp:767:28: error: expected member name or ';' after declaration specifiers
IndicesType>::hasBool, bool>::type
~~~~~~~~~~~~~~~~~~~~~^
Probably unintentional and would-be-nice-if-turned-off, but each time I comment on an issue I get an email with
Run failed for master (e7a2f28)
Repository: coatless/rcppensmallen
Workflow: Commands
Duration: 3.0 seconds
Finished: 2020-01-11 12:33:43 UTC
View results: https://github.com/coatless/rcppensmallen/commit/e7a2f2803f70eb22f08d0f7b2cd578a97c63021a/checks?check_suite_id=395491589
Jobs:
configure.ac
to check for:
It looks like you just gave the automated procedure some love last night but it also looks like it didn't catch this.
Link to paper: https://arxiv.org/abs/1810.09361
Citation:
@ARTICLE{2018arXiv181009361B,
author = {{Bhardwaj}, S. and {Curtin}, R.~R. and {Edel}, M. and {Mentekidis}, Y. and
{Sanderson}, C.},
title = "{ensmallen: a flexible C++ library for efficient function optimization}",
journal = {ArXiv e-prints},
archivePrefix = "arXiv",
eprint = {1810.09361},
primaryClass = "cs.MS",
keywords = {Computer Science - Mathematical Software, Computer Science - Machine Learning, Mathematics - Optimization and Control, 65K10, 68N99, 68W99, 90C53, G.1.6, G.4},
year = 2018,
month = oct,
adsurl = {http://adsabs.harvard.edu/abs/2018arXiv181009361B},
adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}
/cc @conradsnicta
Thank you for creating a great package that is easy to use. However, when creating a R
package with RcppEnsmallen
I am encountering an error that I'm not sure how to address. In the RcppExports.cpp file there are include statements for both Rcpp
and RcppArmadillo
, which is leading to the error "Do not include either 'Rcpp.h' or 'RcppArmadillo.h'. Please only use 'RcppEnsmallen.h'
." Because the RcppExports.cpp file is generated by the Rcpp::compileAttributes()
function I am not sure how to correct this. This is only an issue I've encountered when creating a package, not when running individual script files via Rcpp::sourceCpp()
.
I am a beginner to using Rcpp
so there might be something simple that I am missing. I use devtools
and RStudio for creating packages, and from my understanding devtools::document()
, as well as the RStudio package build/reload tools, automatically calls the Rcpp::compileAttributes()
function. My .cpp file containing functions only begins with the following:
#include <RcppEnsmallen.h>
#include <RcppArmadilloExtensions/sample.h>
// [[Rcpp::plugins("cpp11")]]
// [[Rcpp::depends(RcppEnsmallen)]]
using namespace Rcpp;
In my use of RcppEnsmallen
by just calling Rcpp::sourceCpp()
on scripts rather than developing a package, I do not encounter any errors. I'm not sure what is the proper way to address the RcppExports file however.
Any help would be greatly appreciated, I look forward to continue to use RcppEnsmallen
in my research.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.