Comments (6)
Yes the name is strange and it's not final. It's a proof of concept in a way
look at this example
th.paramset.flat.collection = ParamSetFlat$new(
id = 'th.param.flat.collection',
params = c(
list(
ParamInt$new(id = 'th.param.nat', default = 1L, lower = 1L, upper = 10L)
),
createCollectionParamList(10L, ParamReal$new(id = 'th.param.real.na', default = 0, lower = -10, upper = 10, special.vals = NA))
),
trafo = collectionHelper(fun = function(x, dict, tags) {
xm = as.matrix(as.data.table(x))
col.ind = seq_len(ncol(xm))
ind.mat = sapply(dict$th.param.nat, function(z) col.ind <= z)
ind.mat = t(ind.mat)
xm[!ind.mat] = NA
xm = xm / rowSums(xm, na.rm = TRUE)
list(vector.param = lapply(seq_len(nrow(xm)), function(z) xm[z,]))
}, collection.param.id = "th.param.real.na", additional.params = "th.param.nat")
)
x = th.paramset.flat.collection$sample(3)
th.paramset.flat.collection$transform(x)
from paradox.
it would be much easier
a) to make the baisc functionality of the rest of package work when so much other stuff is still very broken
b) for stuff like this to clearly write down first what you want to achieve.
the docs of collectionHelper dont say a single word about what the intended usage is.
maybe at least write down here what the idea is?
from paradox.
as i have to now guess again what things are supposed to mean:
the problem with scalar param replication is that you later need to figure what belongs together.
in terms of parameters in a set, and in terms of values in a list.
so one should give the user exactly this operation.
from paradox.
Can you read the README and tell me what you would improve?
from paradox.
this doesnt exist anymore? @jakob-r close?
from paradox.
Does not exist anymore.
from paradox.
Related Issues (20)
- .has_extra_trafo when trafo = NULL HOT 1
- How to assign specific value on unmet dependency? HOT 1
- Other parameters besides Uty should have repr
- Add method set_defaults
- Initial values vs defaults HOT 3
- remaining sugar functions
- moving irace parameters implementation to Paradox HOT 5
- Constructing list of `to_tune` objects from `ParamSet` [Question] HOT 2
- ParamSetCollection: trafo
- sugar function for ParamSetCollection
- Autocompletion HOT 1
- Feature request: ps_from_df
- paradox check breaks with to_tune over large param set
- Add "Complex-Default" option to available default values HOT 2
- ParamUty's default custom_check function should be crated
- remove sourcerefs of function values and custom_check
- formatting of `NoDefault` in data.table
- CRAN releases
- Assigning empty tag list to empty parameter set causes a bug HOT 1
- domain_sanitize is broken for negative values
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 paradox.