Skip to content
Merged
10 changes: 5 additions & 5 deletions examples/desktop/gridplot/multigraphic_gridplot.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Example showing a Figure with multiple subplots and multiple graphic types.
"""

# test_example = true
# test_example = false
# sphinx_gallery_pygfx_docs = 'screenshot'

import fastplotlib as fpl
Expand Down Expand Up @@ -58,9 +58,9 @@ def make_circle(center, radius: float, n_points: int = 75) -> np.ndarray:
]

# add an image to overlay the circles on
img2 = np.ones((60, 60))
img2 = iio.imread("imageio:coins.png")[10::5, 5::5]

figure["circles"].add_image(data=img2)
figure["circles"].add_image(data=img2, cmap="gray")

# add the circles to the figure
figure["circles"].add_line_collection(
Expand Down Expand Up @@ -101,8 +101,8 @@ def make_circle(center, radius: float, n_points: int = 75) -> np.ndarray:
gaussian_cloud2 = np.random.multivariate_normal(mean, covariance, n_points)

# add the scatter graphics to the figure
figure["scatter"].add_scatter(data=gaussian_cloud, sizes=1, cmap="jet")
figure["scatter"].add_scatter(data=gaussian_cloud2, colors="r", sizes=1)
figure["scatter"].add_scatter(data=gaussian_cloud, sizes=2, cmap="jet")
figure["scatter"].add_scatter(data=gaussian_cloud2, colors="r", sizes=2)

figure.show()

Expand Down
33 changes: 33 additions & 0 deletions examples/desktop/image/image_small.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
"""
Small Image
===========

Test image to verify dims
"""

import numpy as np

# test_example = true
# sphinx_gallery_pygfx_docs = 'hidden'

import fastplotlib as fpl

figure = fpl.Figure()

data = np.array(
[[0, 1, 2],
[3, 4, 5]]
)
image_graphic = figure[0, 0].add_image(data)

figure.show()

figure.canvas.set_logical_size(700, 560)

figure[0, 0].auto_scale()

# NOTE: `if __name__ == "__main__"` is NOT how to use fastplotlib interactively
# please see our docs for using fastplotlib interactively in ipython and jupyter
if __name__ == "__main__":
print(__doc__)
fpl.run()
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/gridplot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/gridplot_non_square.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/heatmap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 0 additions & 3 deletions examples/desktop/screenshots/heatmap_cmap.png

This file was deleted.

3 changes: 0 additions & 3 deletions examples/desktop/screenshots/heatmap_data.png

This file was deleted.

3 changes: 0 additions & 3 deletions examples/desktop/screenshots/heatmap_vmin_vmax.png

This file was deleted.

4 changes: 2 additions & 2 deletions examples/desktop/screenshots/image_cmap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/image_rgb.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/image_rgbvminvmax.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/image_simple.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions examples/desktop/screenshots/image_small.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/image_vminvmax.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_cmap.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_collection.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_collection_colors.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_collection_slicing.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_colorslice.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_dataslice.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 0 additions & 3 deletions examples/desktop/screenshots/line_present_scaling.png

This file was deleted.

4 changes: 2 additions & 2 deletions examples/desktop/screenshots/line_stack.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 0 additions & 3 deletions examples/desktop/screenshots/multigraphic_gridplot.png

This file was deleted.

3 changes: 0 additions & 3 deletions examples/desktop/screenshots/scatter.png

This file was deleted.

3 changes: 0 additions & 3 deletions examples/desktop/screenshots/scatter_cmap.png
Diff not rendered.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/scatter_cmap_iris.png
3 changes: 0 additions & 3 deletions examples/desktop/screenshots/scatter_colorslice.png
Diff not rendered.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/scatter_colorslice_iris.png
3 changes: 0 additions & 3 deletions examples/desktop/screenshots/scatter_dataslice.png
Diff not rendered.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/scatter_dataslice_iris.png
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/scatter_iris.png
3 changes: 0 additions & 3 deletions examples/desktop/screenshots/scatter_present.png
Diff not rendered.
4 changes: 2 additions & 2 deletions examples/desktop/screenshots/scatter_size.png
4 changes: 2 additions & 2 deletions examples/notebooks/screenshots/nb-astronaut.png
4 changes: 2 additions & 2 deletions examples/notebooks/screenshots/nb-astronaut_RGB.png
4 changes: 2 additions & 2 deletions examples/notebooks/screenshots/nb-camera.png
4 changes: 2 additions & 2 deletions examples/notebooks/screenshots/nb-image-widget-single.png
Loading