Skip to content

Commit

Permalink
Clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
lassepe committed Apr 16, 2024
1 parent 3138603 commit d3c2e97
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 10 deletions.
8 changes: 0 additions & 8 deletions src/Internals.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,6 @@ module Internals

using FastDifferentiation: FastDifferentiation as FD

function parameterize(f::Vector, θ)
f
end

function parameterize(f, θ)
f(θ)
end

function infer_problem_size(lower_bounds, upper_bounds)
if lower_bounds isa AbstractVector
length(lower_bounds)
Expand Down
2 changes: 0 additions & 2 deletions src/parametric_problem.jl
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@ function ParametricMCP(
_jacobian_z! =
SymbolicUtils.build_function(jacobian_z, [z_symbolic; θ_symbolic]; in_place = true)
rows, cols, _ = SparseArrays.findnz(jacobian_z)
# TODO: constant entry detection
constant_entries = get_constant_entries(jacobian_z, z_symbolic)
SparseFunction(rows, cols, size(jacobian_z), constant_entries) do result, z, θ
_jacobian_z!(result, [z; θ])
Expand All @@ -109,7 +108,6 @@ function ParametricMCP(
in_place = true,
)
rows, cols, _ = SparseArrays.findnz(jacobian_θ)
# TODO: constant entry detection
constant_entries = get_constant_entries(jacobian_θ, θ_symbolic)
SparseFunction(rows, cols, size(jacobian_θ), constant_entries) do result, z, θ
_jacobian_θ!(result, [z; θ])
Expand Down

0 comments on commit d3c2e97

Please sign in to comment.