JuliaGaussianProcesses / JuliaGaussianProcesses/ParameterHandling.jl

Should `unflatten` unwrap `Fixed` values?

Open
#37 3 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

I am finally getting around to #30. In doing so I noticed:

julia> x = (1, 2.0, fixed(3.0))
(1, 2.0, ParameterHandling.Fixed{Float64}(3.0))

julia> v, unflatten = flatten(x);

julia> unflatten(v)
(1, 2.0, ParameterHandling.Fixed{Float64}(3.0))

Since wrapping something in Fixed is only done for the sake of the flatten/unflatten machinery, I wonder if it would be better for unflatten to return the unwrapped value of the Fixed number, since that's all end users will generally care about. Or I guess another question to ask is: Are there any situations where the end user would want the Fixed-wrapped value rather than just the value itself?

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 #30 and the three comments on this issue, then reproduce the Julia REPL example with flatten and unflatten. Determine whether unflatten should preserve Fixed wrappers or return their values; done requires a decided behavior and corresponding validation.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.