Skip to content

Commit

Permalink
fix: N/A options for some k less than max_allocations
Browse files Browse the repository at this point in the history
  • Loading branch information
hopeyen committed Sep 7, 2023
1 parent c5596fd commit 8e4f8a0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/AllocationOpt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,9 @@ function main(config::Dict)
# Ensure that the indexer stake is not exceeded
σmax = σ + σpinned
for x in sum(xs; dims=1)
x σmax || error("Tried to allocate more stake than is available by $(x - σmax)")
isnan(x) ||
x σmax ||
error("Tried to allocate more stake than is available by $(x - σmax)")
end

# Write the result values
Expand Down

0 comments on commit 8e4f8a0

Please sign in to comment.