()
| 74 | |
| 75 | |
| 76 | def test_noise(): |
| 77 | np.random.seed(0) |
| 78 | x = np.random.uniform(size=50000) * 50 |
| 79 | |
| 80 | fig, ax = plt.subplots() |
| 81 | p1 = ax.plot(x, solid_joinstyle='round', linewidth=2.0) |
| 82 | |
| 83 | # Ensure that the path's transform takes the new axes limits into account. |
| 84 | fig.canvas.draw() |
| 85 | path = p1[0].get_path() |
| 86 | transform = p1[0].get_transform() |
| 87 | path = transform.transform_path(path) |
| 88 | simplified = path.cleaned(simplify=True) |
| 89 | |
| 90 | assert simplified.vertices.size == 25512 |
| 91 | |
| 92 | |
| 93 | def test_antiparallel_simplification(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…