(self, centroid_only=True, color=None, ax=None, interactive=False)
| 399 | return np.argmin(diff > tol) |
| 400 | |
| 401 | def plot(self, centroid_only=True, color=None, ax=None, interactive=False): |
| 402 | if ax is None: |
| 403 | fig, ax = plt.subplots() |
| 404 | centroid = np.full((self.end + 1, 2), np.nan) |
| 405 | centroid[self.inds] = self.centroid |
| 406 | lines = ax.plot(centroid, c=color, lw=2, picker=interactive) |
| 407 | if not centroid_only: |
| 408 | xy = np.full((self.end + 1, self.xy.shape[1], 2), np.nan) |
| 409 | xy[self.inds] = self.xy |
| 410 | ax.plot(xy[..., 0], c=color, lw=1) |
| 411 | ax.plot(xy[..., 1], c=color, lw=1) |
| 412 | return lines |
| 413 | |
| 414 | |
| 415 | class TrackletStitcher: |
no outgoing calls
no test coverage detected