Skip to content

Iss14#110

Open
Zetison wants to merge 3 commits intoSINTEF:iss14from
Zetison:iss14
Open

Iss14#110
Zetison wants to merge 3 commits intoSINTEF:iss14from
Zetison:iss14

Conversation

@Zetison
Copy link
Copy Markdown

@Zetison Zetison commented Feb 19, 2020

Fix #108

@VikingScientist
Copy link
Copy Markdown
Member

This needs to be rebased on master

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR addresses #108 by updating order elevation so non-open (unclamped) and periodic knot vectors are handled by falling back to an implicit/interpolation-based implementation, while introducing an explicit order-elevation algorithm intended for open knot vectors.

Changes:

  • Updated SplineObject.raise_order to route non-open/periodic cases to a new raise_order_implicit method and added an explicit open-knot-vector path.
  • Added a new raise_order_1D helper (derivative-based degree elevation) used by the explicit path.
  • Renamed Curve.raise_order to Curve.raise_order_implicit to align with the new dispatch behavior.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.

File Description
splipy/utils/init.py Updates __all__ exports (currently adds an invalid export).
splipy/SplineObject.py Adds explicit order elevation, implicit fallback, and a new 1D helper implementation.
splipy/Curve.py Renames curve-specific order elevation implementation to raise_order_implicit.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread splipy/utils/__init__.py
'check_section', 'check_direction', 'ensure_flatlist', 'is_singleton',
'ensure_listlike', 'rotate_local_x_axis', 'flip_and_move_plane_geometry',
'reshape',
'reshape','raise_order_1D'
Comment thread splipy/SplineObject.py
from splipy import BSplineBasis
from splipy.utils import reshape, rotation_matrix, is_singleton, ensure_listlike,\
check_direction, ensure_flatlist, check_section, sections
import splipy.state as state
Comment thread splipy/SplineObject.py
Comment on lines +444 to +445
self.raise_order_implicit(*raises)
return
Comment thread splipy/SplineObject.py
Comment on lines +442 to +443

if any(not(b.continuity(b.knots[0]) == -1) or b.periodic > -1 for b in self.bases):
Comment thread splipy/SplineObject.py
Comment on lines +1483 to +1486
Qt[:,0,indices] = np.multiply(Pt[:,0,indices],np.reshape(alpha[indices],(1,1,k))) # (21)
for p in range(0,S):
indices = range(k-z[p],k)
Qt[:,beta[p]+p*m,indices] = np.multiply(Pt[:,beta[p],indices],np.reshape(alpha[indices],(1,1,z[p]))) # (22)
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.

3 participants