Skip to content

Conversation

@philipc2
Copy link
Member

@philipc2 philipc2 commented Mar 18, 2025

Overview

  • Fixes the benchmark workflow, which was failing due to environment and permission issues
  • Fixes broken benchmarks.

* Update environment.yml

* Update mpas_ocean.py
@philipc2 philipc2 self-assigned this Mar 18, 2025
@philipc2 philipc2 added the run-benchmark Run ASV benchmark workflow label Mar 18, 2025
@github-actions
Copy link

github-actions bot commented Mar 18, 2025

ASV Benchmarking

Benchmark Comparison Results

Benchmarks that have improved:

Change Before [a7ed060] After [5f58d3f] Ratio Benchmark (Parameter)
- 745M 440M 0.59 face_bounds.FaceBounds.peakmem_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/ugrid/quad-hexagon/grid.nc'))
- 16.6±0.07μs 15.1±0.09μs 0.91 face_bounds.FaceBounds.time_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/mpas/QU/oQU480.231010.nc'))
- 531M 423M 0.8 mpas_ocean.Integrate.peakmem_integrate('480km')

Benchmarks that have stayed the same:

Change Before [a7ed060] After [5f58d3f] Ratio Benchmark (Parameter)
440M 440M 1 face_bounds.FaceBounds.peakmem_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/mpas/QU/oQU480.231010.nc'))
470M 472M 1 face_bounds.FaceBounds.peakmem_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/scrip/outCSne8/outCSne8.nc'))
479M 443M 0.92 face_bounds.FaceBounds.peakmem_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/ugrid/geoflow-small/grid.nc'))
9.38±0.1μs 8.80±0.05μs 0.94 face_bounds.FaceBounds.time_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/scrip/outCSne8/outCSne8.nc'))
44.3±0.5ms 43.2±0.1ms 0.97 face_bounds.FaceBounds.time_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/ugrid/geoflow-small/grid.nc'))
3.75±0.1ms 3.65±0.1ms 0.98 face_bounds.FaceBounds.time_face_bounds(PosixPath('/home/runner/work/uxarray/uxarray/test/meshfiles/ugrid/quad-hexagon/grid.nc'))
11.4±0.01s 11.4±0.02s 1 import.Imports.timeraw_import_uxarray
757±1μs 753±1μs 1 mpas_ocean.CheckNorm.time_check_norm('120km')
498±2μs 505±10μs 1.01 mpas_ocean.CheckNorm.time_check_norm('480km')
644±7ms 636±20ms 0.99 mpas_ocean.ConnectivityConstruction.time_face_face_connectivity('120km')
42.0±0.5ms 41.5±1ms 0.99 mpas_ocean.ConnectivityConstruction.time_face_face_connectivity('480km')
5.62±0.03μs 5.54±0.03μs 0.99 mpas_ocean.ConnectivityConstruction.time_n_nodes_per_face('120km')
5.55±0.02μs 5.54±0.01μs 1 mpas_ocean.ConnectivityConstruction.time_n_nodes_per_face('480km')
5.11±0.02ms 5.10±0.02ms 1 mpas_ocean.ConstructFaceLatLon.time_cartesian_averaging('120km')
3.82±0.03ms 3.84±0.03ms 1.01 mpas_ocean.ConstructFaceLatLon.time_cartesian_averaging('480km')
3.50±0.02s 3.49±0s 1 mpas_ocean.ConstructFaceLatLon.time_welzl('120km')
229±2ms 224±1ms 0.98 mpas_ocean.ConstructFaceLatLon.time_welzl('480km')
673±2ns 669±4ns 0.99 mpas_ocean.ConstructTreeStructures.time_ball_tree('120km')
277±4ns 280±1ns 1.01 mpas_ocean.ConstructTreeStructures.time_ball_tree('480km')
530±0.3ns 509±1ns 0.96 mpas_ocean.ConstructTreeStructures.time_kd_tree('120km')
278±3ns 283±5ns 1.02 mpas_ocean.ConstructTreeStructures.time_kd_tree('480km')
449±5ms 445±2ms 0.99 mpas_ocean.CrossSections.time_const_lat('120km', 1)
230±2ms 228±2ms 0.99 mpas_ocean.CrossSections.time_const_lat('120km', 2)
118±1ms 118±0.7ms 1 mpas_ocean.CrossSections.time_const_lat('120km', 4)
373±5ms 376±4ms 1.01 mpas_ocean.CrossSections.time_const_lat('480km', 1)
189±0.7ms 188±0.7ms 1 mpas_ocean.CrossSections.time_const_lat('480km', 2)
98.9±1ms 96.9±0.3ms 0.98 mpas_ocean.CrossSections.time_const_lat('480km', 4)
125±2ms 123±1ms 0.99 mpas_ocean.DualMesh.time_dual_mesh_construction('120km')
9.49±0.2ms 9.27±0.05ms 0.98 mpas_ocean.DualMesh.time_dual_mesh_construction('480km')
1.10±0.01s 1.07±0.01s 0.98 mpas_ocean.GeoDataFrame.time_to_geodataframe('120km', False)
1.27±0.02ms 1.19±0.01ms 0.94 mpas_ocean.GeoDataFrame.time_to_geodataframe('120km', True)
88.2±1ms 84.1±0.3ms 0.95 mpas_ocean.GeoDataFrame.time_to_geodataframe('480km', False)
4.97±0.09ms 4.87±0.04ms 0.98 mpas_ocean.GeoDataFrame.time_to_geodataframe('480km', True)
427M 427M 1 mpas_ocean.Gradient.peakmem_gradient('120km')
409M 409M 1 mpas_ocean.Gradient.peakmem_gradient('480km')
2.72±0.02ms 2.73±0.01ms 1.01 mpas_ocean.Gradient.time_gradient('120km')
313±3μs 317±4μs 1.01 mpas_ocean.Gradient.time_gradient('480km')
244±3μs 239±2μs 0.98 mpas_ocean.HoleEdgeIndices.time_construct_hole_edge_indices('120km')
119±0.9μs 119±2μs 1 mpas_ocean.HoleEdgeIndices.time_construct_hole_edge_indices('480km')
437M 437M 1 mpas_ocean.Integrate.peakmem_integrate('120km')
147±3ms 153±4ms 1.04 mpas_ocean.Integrate.time_integrate('120km')
10.9±0.5ms 10.3±0.3ms 0.94 mpas_ocean.Integrate.time_integrate('480km')
343±2ms 344±4ms 1 mpas_ocean.MatplotlibConversion.time_dataarray_to_polycollection('120km', 'exclude')
345±3ms 342±3ms 0.99 mpas_ocean.MatplotlibConversion.time_dataarray_to_polycollection('120km', 'include')
342±2ms 344±4ms 1.01 mpas_ocean.MatplotlibConversion.time_dataarray_to_polycollection('120km', 'split')
21.9±0.1ms 21.9±0.04ms 1 mpas_ocean.MatplotlibConversion.time_dataarray_to_polycollection('480km', 'exclude')
22.0±0.09ms 21.9±0.09ms 1 mpas_ocean.MatplotlibConversion.time_dataarray_to_polycollection('480km', 'include')
22.1±0.08ms 21.9±0.01ms 0.99 mpas_ocean.MatplotlibConversion.time_dataarray_to_polycollection('480km', 'split')
4.50±0.02ms 4.53±0.05ms 1.01 mpas_ocean.PointInPolygon.time_face_search('120km')
4.63±0.06ms 4.58±0.08ms 0.99 mpas_ocean.PointInPolygon.time_face_search('480km')
55.0±0.06ms 55.2±0.2ms 1 mpas_ocean.RemapDownsample.time_inverse_distance_weighted_remapping
44.7±0.03ms 45.3±0.04ms 1.01 mpas_ocean.RemapDownsample.time_nearest_neighbor_remapping
355±0.6ms 357±1ms 1 mpas_ocean.RemapUpsample.time_inverse_distance_weighted_remapping
260±0.7ms 262±0.7ms 1.01 mpas_ocean.RemapUpsample.time_nearest_neighbor_remapping
25.6±0.2ms 25.6±0.3ms 1 mpas_ocean.ZonalAverage.time_zonal_average('120km')
4.63±0ms 4.44±0.02ms 0.96 mpas_ocean.ZonalAverage.time_zonal_average('480km')
408M 407M 1 quad_hexagon.QuadHexagon.peakmem_open_dataset
405M 405M 1 quad_hexagon.QuadHexagon.peakmem_open_grid
7.63±0.1ms 7.38±0.07ms 0.97 quad_hexagon.QuadHexagon.time_open_dataset
6.53±0.02ms 6.50±0.07ms 1 quad_hexagon.QuadHexagon.time_open_grid

@philipc2 philipc2 changed the title Update environment.yml to fix ASV PR workflow Fix ASV Benchmarking Workflow Mar 18, 2025
@philipc2 philipc2 removed the run-benchmark Run ASV benchmark workflow label Mar 18, 2025
@philipc2 philipc2 added the run-benchmark Run ASV benchmark workflow label Mar 18, 2025
@philipc2 philipc2 removed the run-benchmark Run ASV benchmark workflow label Mar 18, 2025
@philipc2 philipc2 merged commit 6c39393 into main Mar 18, 2025
20 checks passed
@erogluorhan erogluorhan deleted the fix-asv-pr branch September 26, 2025 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants