Skip to content

Working with complex custom objectives #353

Answered by MilesCranmer
DenisSvirin asked this question in Q&A
Discussion options

You must be logged in to vote

You mean like this?

    attraction_func = tree.l.r
    attraction = tree.l.l
    attraction_func_val, flag = eval_tree_array(attraction_func, dataset.X, options)
    !flag && return L(Inf)
    attraction_val, flag = eval_tree_array(attraction, dataset.X, options)
    !flag && return L(Inf)

    result = attraction_func_val ^ attraction_val

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@DenisSvirin
Comment options

@MilesCranmer
Comment options

@DenisSvirin
Comment options

@MilesCranmer
Comment options

Answer selected by DenisSvirin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
PySR PySR-related discussion SymbolicRegression.jl SymbolicRegression.jl-related discussion
2 participants