Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move StaticArrays to extension #173

Merged
merged 4 commits into from
May 28, 2023
Merged

Conversation

longemen3000
Copy link
Contributor

there is a lot of x isa StaticArray ? Val(false) : Val(true). those were replaced by a wrapper to ArrayInterface.ismutable

@ChrisRackauckas
Copy link
Member

Nice! It does look like one more dispatch needs to move to the extension and it will be good to go.

@@ -36,16 +47,15 @@ function finite_difference_hessian(
cache::HessianCache{T,fdtype,inplace};
relstep=default_relstep(fdtype, eltype(x)),
absstep=relstep) where {T,fdtype,inplace}
_H = false .* x .* x'
_H isa SMatrix ? H = MArray(_H) : H = _H
H = mutable_zeromatrix(x)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this defined?

Copy link
Contributor Author

@longemen3000 longemen3000 May 22, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

at the start of hessians.jl. uses ArrayInterface.zeromatrix + ArrayInterface.ismutable + Base.copymutable. was looking for something like that in ArrayInterface, but couldn't find it

@ChrisRackauckas ChrisRackauckas merged commit 9b6b428 into JuliaDiff:master May 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants