Skip to main content
Ctrl+K
scikit-plots homepage scikit-plots homepage
  • Introduction
  • User Guide
  • APIs Reference
  • Tutorials
  • Learn
  • Tags
    • Affiliated Packages
    • Code of Conduct
    • Community
    • Developer's Guide
    • Governance Process
    • Release History
    • Roadmap
    • About Us | Project
  • Social Media Platforms
  • PyPI
  • GitHub
  • Introduction
  • User Guide
  • APIs Reference
  • Tutorials
  • Learn
  • Tags
  • Affiliated Packages
  • Code of Conduct
  • Community
  • Developer's Guide
  • Governance Process
  • Release History
  • Roadmap
  • About Us | Project
  • Social Media Platforms
  • PyPI
  • GitHub

Section Navigation

  • ANNoy
    • Getting started
    • Architecture
    • Persistence and I/O
    • Performance and threads
    • Python API
    • Limits and troubleshooting
    • Vector Similarity Search and Vector Database
    • Annoy Index class Inheritance Diagrams (MRO)
    • ANNoy Cython
  • Metric Performance
    • Decomposition
    • Estimators
    • Metrics
  • CleanPrompt
    • Getting started
    • How it works
    • The Python API
    • The command line
    • Names, organisations and places
    • Files, records, packs and plans
    • Models, tools and agents
    • The web page and containers
    • What it protects, and what it does not
    • Troubleshooting and questions
  • Corpus
    • Getting started
    • Architecture
    • Readers, backends, and readiness
    • Fluent configuration and policies
    • Customization
    • Downloads and network boundaries
    • Retrieval and similarity
    • Formats, structured evidence, and export
    • Security and limits
    • Troubleshooting
  • Cython
    • Getting started
    • Trust and security
    • Build, cache, and import
    • Profiles and toolchains
    • Packages, templates, and workflows
    • Cache, pins, and garbage collection
    • Python API
    • Troubleshooting
    • Cython templates
      • basic_cython
      • basic_python
      • complex_cython
      • complex_python
      • devel_cython
      • devel_numcpp_cpp_api_cython
      • devel_numcpp_cpp_api_python
      • devel_numpy_c_api_cython
      • devel_numpy_c_api_python
      • devel_python
      • easy_cython
      • easy_python
      • hard_cython
      • hard_python
      • medium_cython
      • medium_python
      • mixed
      • module_cython
      • module_python
  • Decile analysis
    • Getting started
    • KDS functions
    • ModelPlotPy
    • Business and financial plots
    • Compatibility and limits
  • Missing-value imputation
    • Getting started
    • Standard imputers
    • ANNImputer
    • Index access and privacy
    • Python API
    • Limits and troubleshooting
  • Levenshtein
    • Getting started
    • How it works
    • Backends and fallback
    • Ranking and matching
    • Corpus integration
    • Performance and limits
    • Troubleshooting
  • Logging
    • Getting started
    • Levels and loggers
    • Formatting and helpers
    • Python API
    • Known limits and troubleshooting
  • MemMap
    • Getting started
    • Lifecycle and I/O
    • Protection, sync, and locking
    • Python API
    • Platform and limits
  • Mcp
    • Getting started
    • Architecture
    • Retrieval and fusion
    • Corpus and Annoy
    • Capabilities and runtime
    • Server, CLI, and security
    • Deployment and operations
    • Python API
    • Troubleshooting
    • Model Context Protocol (MCP)
  • MLflow
    • Getting started
    • Project configuration
    • Sessions and facades
    • Server and CLI
    • Providers and workflows
    • Security and readiness
    • Python API
    • Troubleshooting
  • Nc
  • Categorical preprocessing
    • Getting started
    • GetDummies
    • DummyCodeEncoder
    • Scikit-learn integration
    • Python API
    • Known limits and troubleshooting
  • KISS random number generation
    • Getting started
    • Generators and seeding
    • State and serialization
    • NumPy interop and reproducibility
    • Python API
    • Limits and troubleshooting
  • Rank-BM25
    • Getting started
    • Recipes and tokenization
    • Retrieval and identity
    • Persistence and reproducibility
    • Performance and scaling
    • Python API
    • Troubleshooting
    • Rank-BM25 Usage Scenarios
  • Seaborn
    • Getting started
    • AUC and evaluation
    • Decile and model plots
    • Data semantics and styling
    • Python API
    • Known limits and troubleshooting
  • Stats
  • Keras architecture visualization
    • Getting started
    • Layered view
    • Graph view
    • Styling and spacing
    • Python API
    • Dependencies and limits
    • Troubleshooting
  • Array API support
  • Brand
    • CLI Banner
    • Logo

development

  • C-Experimental (experimental)
  • C-Externals (experimental)
    • spotify/ANNoy Vector Index DB
    • Astropy (experimental)
    • f2py (experimental)
    • NumCpp
    • LightNumPy (experimental)
  • Experimental (experimental)
    • Pipeline
    • Do-Re-Mi
  • Externals (experimental)
    • array_api_compat
    • array_api_extra
    • Probability Plots (experimental)
    • Seaborn (experimental)
    • Matplotlib Sphinx Ext
    • Tweedie Family
  • Externals (experimental)
    • Jupyter Ext
    • Sphinx Ext
      • ANSI Sanitizer
      • PyData Component List
      • Sphinx AI Assistant
      • Sphinx AI Learn
      • Sphinx Collection
      • Sphinx Feedback
      • Sphinx Gallery Grid
      • Sphinx-Gallery JupyterLite
      • Sphinx Jinja Render
      • Sphinx LLM
      • Sphinx YouTube Core
      • Sphinx YouTube Gallery
      • Sphinx Video Directives
  • User Guide
  • Externals (experimental)
  • Bundled Sphinx extensions (experimental)
  • Sphinx Gallery Grid

Sphinx Gallery Grid#

_sphinx_gallery_grid provides the theme-independent gallery-grid directive for structured card collections. Records can be written inline as YAML or loaded from a UTF-8 YAML file. The directive delegates card rendering to Sphinx Design and delegates generic selection/browser behavior to Sphinx collection engine.

Enable it#

extensions += [
    "scikitplot._externals._sphinx_ext._sphinx_gallery_grid",
]

The extension loads sphinx_design itself.

Minimal gallery#

.. gallery-grid::
   :grid-columns: 1 1 2 3

   - title: Getting started
     content: Install the package and make a first plot.
     link: ../../../index
     link-alt: Open the guide
   - title: API reference
     content: Browse the documented public API.
     link: ../../../../apis/index
     link-alt: Open the API reference

Card records may carry presentation fields such as title, header, image, content and link plus additional data-only fields used by filtering, sorting or grouping.

File-backed gallery#

.. gallery-grid:: ./_data/resources.yaml
   :sort: title
   :group-by: category
   :show-count:

File paths are resolved relative to the authoring document and are confined to the Sphinx source/configuration tree after symlink resolution. A gallery cannot use a relative path to read arbitrary files elsewhere on the build host.

Build-time selection#

The directive supports build-time operations including:

  • :filter: for field predicates;

  • :sort: for deterministic ordering;

  • :group-by: for top-level sections;

  • :offset: and :limit: for build-time slicing;

  • :show-count: for an honest selected/total count.

Build-time limit is distinct from the browser’s bounded display window. Once records are omitted by the build-time selection, browser controls cannot recover them.

Interactive reader controls#

Use :searchable: or :interactive: to activate the shared collection browser. Both accept the configured search presentation, and a directive can override it with :search-variant:. The current variants are pill-overflow and classic.

Useful controls include :filter-fields:, :sort-fields:, :search-fields:, :search-label: and a stable :collection-id:. Interactive views use the shared bounded-card display controller rather than rendering a second gallery implementation.

Presentation customization#

grid-* options are validated using the installed Sphinx Design grid option specification, and card-* options use Sphinx Design’s card specification. The directive also accepts grid-columns, class-container and class-card conveniences.

Option values that are re-emitted as generated directive source must stay on one line. URL-like presentation options reject active schemes; card links accept HTTP(S), mailto and relative/fragment destinations.

Input safety#

Inline and file-backed YAML use the shared bounded loader documented in Sphinx collection engine. Python-object YAML constructors are not accepted, recursive aliases are rejected, and collection/resource limits are applied before rendering.

MyST documents#

The implementation detects the source parser and emits matching nested Sphinx Design syntax, so the same extension can be used from reStructuredText and MyST sources. Authors do not need a separate gallery implementation for Markdown.

previous

Sphinx Feedback

next

Sphinx-Gallery JupyterLite helpers

On this page
  • Enable it
  • Minimal gallery
  • File-backed gallery
  • Build-time selection
  • Interactive reader controls
  • Presentation customization
  • Input safety
  • MyST documents
Edit on GitHub
Show Source

© Copyright 2024 - 2026 scikit-plots developers (BSD-3 Clause License) 0.5.dev0+git.20261011.0ec25c0 2026-10-11T11:42Z.