gdsfactory.path.smooth

Contents

gdsfactory.path.smooth#

gdsfactory.path.smooth(points: tuple[tuple[float, float], ...] | list[tuple[float, float]], radius: float = 4.0, bend: ~collections.abc.Callable[[...], ~gdsfactory.path.Path] = <function euler>, **kwargs) Path[source]#

Returns a smooth Path from a series of waypoints.

Parameters:
  • points – array-like[N][2] List of waypoints for the path to follow.

  • radius – radius of curvature, passed to bend.

  • bend – bend function that returns a path that round corners.

  • kwargs – Extra keyword arguments that will be passed to bend.

import gdsfactory as gf

p = gf.path.smooth(([0, 0], [0, 10], [10, 10]))
p.plot()

(Source code, png, hires.png, pdf)

../_images/gdsfactory-path-smooth-1.png