Skip to content

Connectivity benchmarks #1549

Merged
rajeeja merged 6 commits into
UXARRAY:mainfrom
cmdupuis3:cmdupuis3/connectivity_benchmarks
Jul 7, 2026
Merged

Connectivity benchmarks #1549
rajeeja merged 6 commits into
UXARRAY:mainfrom
cmdupuis3:cmdupuis3/connectivity_benchmarks

Conversation

@cmdupuis3

@cmdupuis3 cmdupuis3 commented Jul 6, 2026

Copy link
Copy Markdown
Collaborator

This PR adds benchmarks for basic connectivity routines.

Helps with Issue #1196

Overview

This PR adds benchmarks for the pairwise connectivity routines (face, edge, node). Two of the nine are apparently unimplemented and are included as TODOs: node/node and edge/edge. We can delete them if they don't make sense.

Expected Usage

Waiting for merge to see real timings on larger grids on Glade, the smaller ones may be too small to sample reliably.

Run benchmarks with asv:

asv run --python=same --bench "bench_connectivity.Connectivity"

PR Checklist

General

  • [ x ] An issue is linked created and linked
  • [ x ] Add appropriate labels
  • [ x ] Filled out Overview and Expected Usage (if applicable) sections

Testing

  • [N/A] Adequate tests are created if there is new functionality
  • [ x ] Tests cover all possible logical paths in your function
  • [N/A] Tests are not too basic (such as simply calling a function and nothing else)

Documentation

  • Docstrings have been added to all new functions
  • Docstrings have updated with any function changes
  • [N/A] Internal functions have a preceding underscore (_) and have been added to docs/internal_api/index.rst
  • [N/A] User functions have been added to docs/user_api/index.rst

@cmdupuis3 cmdupuis3 requested a review from erogluorhan July 6, 2026 20:04
@cmdupuis3 cmdupuis3 added the benchmarking Related to benchmarks, memory usage, and/or time profiling label Jul 6, 2026
@cmdupuis3 cmdupuis3 requested a review from rajeeja July 7, 2026 02:33

@rajeeja rajeeja left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for adding these. One issue: the DYAMOND path entries are strings, but setup() indexes them with [0], so 30km becomes / and ASV fails locally. Can you make those entries lists/tuples like the oQU entries, or adjust setup() to accept both forms?

@cmdupuis3

Copy link
Copy Markdown
Collaborator Author

Thanks for adding these. One issue: the DYAMOND path entries are strings, but setup() indexes them with [0], so 30km becomes / and ASV fails locally. Can you make those entries lists/tuples like the oQU entries, or adjust setup() to accept both forms?

Oops, I'll just get rid of the data file paths. These benchmarks don't need them anyway.

@cmdupuis3 cmdupuis3 requested a review from rajeeja July 7, 2026 16:22

@rajeeja rajeeja left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update, looks good now.

@rajeeja rajeeja merged commit a3614aa into UXARRAY:main Jul 7, 2026
13 checks passed
@cmdupuis3 cmdupuis3 added run-benchmark Run ASV benchmark workflow and removed run-benchmark Run ASV benchmark workflow labels Jul 7, 2026
@rajeeja rajeeja moved this to 👀 In review in UXarray Development Jul 8, 2026
@github-project-automation github-project-automation Bot moved this from 👀 In review to ✅ Done in UXarray Development Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

benchmarking Related to benchmarks, memory usage, and/or time profiling

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

2 participants