0.3.0

PyPI link to release 0.3.0 Documentation for release 0.3.0

Performance Optimizations

  • Adding __slots__ for all classes

  • Removing all usage of @property calls from internal callers (to avoid function call overhead)

  • Avoiding un-necessary data copying, e.g. nodes[[0], :] creates a copy but nodes[0, :].reshape((1, 2)) does not (more details)

  • Adding _verify switches to selectively disable overly defensive value checking. Added to CurvedPolygon constructor, Surface.evaluate_barycentric() (doc), Surface.evaluate_cartesian() (doc), Surface.evaluate_multi() (doc) and Surface.intersect() (doc). Internal callers with already verified data now skip verification steps

  • Bailing out early if surface bounding boxes are disjoint in Surface.intersect() method

Breaking Changes

  • Requiring degree in Curve (doc) and Surface (doc) constructors, but adding Curve.from_nodes() (doc) and Surface.from_nodes() (doc) factories to accept nodes only (computing the degree in the constructor every time is a waste of flops, especially if the caller knows the degree)

  • Removing public Curve.copy() (doc) and Surface.copy() (doc)

  • Removing custom equality checks for Curve (doc) and Surface (doc) objects. The previous implementation did not factor in all relevant values

  • Returning 1xD arrays instead of flattened D-dimensional 1D arrays from Curve.evaluate() (doc), Surface.evaluate_barycentric() (doc), Surface.evaluate_cartesian() (doc), and related helpers

  • Renaming Intersection.left/right properties as first/second properties (They were poorly named originally, since “left” and “right” were in reference to where they were used in code, not geometry. This class is not part of the public interface, but it is documented.)

Bug Fixes

  • Handling cases where one corner of a surface touches another but their interiors don’t intersect (in the Surface.intersect() method). Adding ignored_corner classification to handle these curve-curve intersecions that don’t contribute to a surface-surface intersection

  • Throwing exception in the Curve.locate() method when the subdivided intervals are very far apart (#13)

  • Improving Surface.is_valid property by considering the signs of the Jacobian determinant at corner nodes (#12)

Miscellany

  • Adding possible strategy to avoid linear convergence in newton_refine() helper

  • Adding AppVeyor configuration to make sure there are no Windows issues, testing exclusively with conda install

  • Updating generated images with matplotlib 2.0