JuliaGaussianProcesses / JuliaGaussianProcesses/ParameterHandling.jl

AbstractArray -> StridedArray

Open
#22 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Julia
Stars
74
Forks
10
PR merge metrics
No merged PRs in 30d

Description

#21 essentially points out that we have the same problem that we see regularly in the AD world, where a sensible implementation of flatten for e.g. a sparse array or Fill is not the same as a sensible implementation for e.g. a StridedArray.

Should be a quick fix. We probably need to copy over + tweak the code for to_vec for general structs so that flatten gives you the struct interpretation of an array by default.

Disclaimer: I'm assuming thay if a user writes Fill(5.0, 10) then they want to constrain this vector to be a Fill throughout e.g. optimisation, and that if this weren't the case said user would write fill(5.0, 10).

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading issue #21 and locating the existing to_vec implementation and flatten entry points. Compare behavior for general structs, sparse arrays, Fill, and StridedArray; done means flatten uses the struct interpretation by default while preserving sensible specialized behavior for array types.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
40/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.