Skip to content

[WIP] Allow more general knot sequences#5

Draft
sostock wants to merge 26 commits into
masterfrom
knotsequences
Draft

[WIP] Allow more general knot sequences#5
sostock wants to merge 26 commits into
masterfrom
knotsequences

Conversation

@sostock

@sostock sostock commented Jul 25, 2020

Copy link
Copy Markdown
Owner

This PR attempts to implement support for knot sequences where the first and last breakpoints appear less than order(basis) times. It is currently work in progress, and at a very early stage.

  • Store knots instead of breakpoints in BSplineBasis
  • Add a constructor with keyword arguments to be able to specify the knot vector instead of the breakpoints: BSplineBasis(k, knots=...) and BSplineBasis(k, breakpoints=...). Deprecate the old (non-keyword) constructor.
  • Allow indexing into a BSplineBasis with a UnitRange to create a new BSplineBasis. Support view as well.
  • Make bsplines/bsplines! return an OffsetArray of a view.
  • Modify bsplines/bsplines!/splinevalue to work with the new knot vectors.
  • Deprecate indices keyword argument, recommend to use view(::BSplineBasis, ...) instead.
  • Update documentation

@sostock sostock mentioned this pull request Jul 25, 2020
3 tasks
@codecov-io

codecov-io commented Feb 12, 2021

Copy link
Copy Markdown

Codecov Report

Merging #5 (633ac00) into master (342976f) will increase coverage by 0.29%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master       #5      +/-   ##
==========================================
+ Coverage   95.20%   95.50%   +0.29%     
==========================================
  Files           6        6              
  Lines         501      534      +33     
==========================================
+ Hits          477      510      +33     
  Misses         24       24              
Impacted Files Coverage Δ
src/plotting.jl 34.37% <ø> (ø)
src/BSplines.jl 100.00% <100.00%> (ø)
src/bsplinebasis.jl 99.67% <100.00%> (+0.03%) ⬆️
src/spline.jl 97.61% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 342976f...633ac00. Read the comment docs.

Repository owner deleted a comment from codecov-commenter Feb 12, 2021
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