DynamicExpressions.jl icon indicating copy to clipboard operation
DynamicExpressions.jl copied to clipboard

Overflow turns the whole batch to `NaN`s

Open nmheim opened this issue 7 months ago • 5 comments

Hey! Thanks a lot for this, I really like the package!:)

I seems like an overflow in one of the samples causes the whole batch to be turned into NaNs:

using DynamicExpressions

T = Float64
x = Node{T}(feature=1)
ops = OperatorEnum(binary_operators=[*])
expr = x*2

julia> X = ones(1,2)
julia> expr(X, ops)
2-element Vector{Float64}:
 2.0
 2.0

julia> X[2] = floatmax(T)
julia> expr(X, ops)
2-element Vector{Float64}:
 NaN
 NaN

nmheim avatar Jun 28 '24 12:06 nmheim