@@ -237,7 +237,8 @@ def test_matshow(fig_test, fig_ref):
237237 'formatter_ticker_003' ,
238238 'formatter_ticker_004' ,
239239 'formatter_ticker_005' ,
240- ])
240+ ],
241+ tol = 0.031 if platform .machine () == 'arm64' else 0 )
241242def test_formatter_ticker ():
242243 import matplotlib .testing .jpl_units as units
243244 units .register ()
@@ -437,7 +438,8 @@ def test_twin_logscale(fig_test, fig_ref, twin):
437438 remove_ticks_and_titles (fig_ref )
438439
439440
440- @image_comparison (['twin_autoscale.png' ])
441+ @image_comparison (['twin_autoscale.png' ],
442+ tol = 0.009 if platform .machine () == 'arm64' else 0 )
441443def test_twinx_axis_scales ():
442444 x = np .array ([0 , 0.5 , 1 ])
443445 y = 0.5 * x
@@ -1232,7 +1234,8 @@ def test_fill_betweenx_input(y, x1, x2):
12321234 ax .fill_betweenx (y , x1 , x2 )
12331235
12341236
1235- @image_comparison (['fill_between_interpolate' ], remove_text = True )
1237+ @image_comparison (['fill_between_interpolate' ], remove_text = True ,
1238+ tol = 0.012 if platform .machine () == 'arm64' else 0 )
12361239def test_fill_between_interpolate ():
12371240 x = np .arange (0.0 , 2 , 0.02 )
12381241 y1 = np .sin (2 * np .pi * x )
@@ -1623,7 +1626,7 @@ def test_pcolorauto(fig_test, fig_ref, snap):
16231626 ax .pcolormesh (x2 , y2 , Z , snap = snap )
16241627
16251628
1626- @image_comparison (['canonical' ])
1629+ @image_comparison (['canonical' ], tol = 0.02 if platform . machine () == 'arm64' else 0 )
16271630def test_canonical ():
16281631 fig , ax = plt .subplots ()
16291632 ax .plot ([1 , 2 , 3 ])
@@ -3065,7 +3068,8 @@ def test_log_scales_invalid():
30653068 ax .set_ylim (- 1 , 10 )
30663069
30673070
3068- @image_comparison (['stackplot_test_image' , 'stackplot_test_image' ])
3071+ @image_comparison (['stackplot_test_image' , 'stackplot_test_image' ],
3072+ tol = 0.031 if platform .machine () == 'arm64' else 0 )
30693073def test_stackplot ():
30703074 fig = plt .figure ()
30713075 x = np .linspace (0 , 10 , 10 )
@@ -4873,7 +4877,8 @@ def test_marker_styles():
48734877 marker = marker , markersize = 10 + y / 5 , label = marker )
48744878
48754879
4876- @image_comparison (['rc_markerfill.png' ])
4880+ @image_comparison (['rc_markerfill.png' ],
4881+ tol = 0.037 if platform .machine () == 'arm64' else 0 )
48774882def test_markers_fillstyle_rcparams ():
48784883 fig , ax = plt .subplots ()
48794884 x = np .arange (7 )
@@ -4896,7 +4901,7 @@ def test_vertex_markers():
48964901
48974902
48984903@image_comparison (['vline_hline_zorder' , 'errorbar_zorder' ],
4899- tol = 0 if platform .machine () == 'x86_64' else 0.02 )
4904+ tol = 0 if platform .machine () == 'x86_64' else 0.026 )
49004905def test_eb_line_zorder ():
49014906 x = list (range (10 ))
49024907
@@ -5455,7 +5460,8 @@ def test_twin_remove(fig_test, fig_ref):
54555460 ax_ref .yaxis .tick_left ()
54565461
54575462
5458- @image_comparison (['twin_spines.png' ], remove_text = True )
5463+ @image_comparison (['twin_spines.png' ], remove_text = True ,
5464+ tol = 0.022 if platform .machine () == 'arm64' else 0 )
54595465def test_twin_spines ():
54605466
54615467 def make_patch_spines_invisible (ax ):
@@ -5822,7 +5828,7 @@ def test_pie_linewidth_0():
58225828 plt .axis ('equal' )
58235829
58245830
5825- @image_comparison (['pie_center_radius.png' ], style = 'mpl20' , tol = 0.005 )
5831+ @image_comparison (['pie_center_radius.png' ], style = 'mpl20' , tol = 0.007 )
58265832def test_pie_center_radius ():
58275833 # The slices will be ordered and plotted counter-clockwise.
58285834 labels = 'Frogs' , 'Hogs' , 'Dogs' , 'Logs'
@@ -6008,7 +6014,8 @@ def test_pie_hatch_multi(fig_test, fig_ref):
60086014 [w .set_hatch (hp ) for w , hp in zip (wedges , hatch )]
60096015
60106016
6011- @image_comparison (['set_get_ticklabels.png' ])
6017+ @image_comparison (['set_get_ticklabels.png' ],
6018+ tol = 0.025 if platform .machine () == 'arm64' else 0 )
60126019def test_set_get_ticklabels ():
60136020 # test issue 2246
60146021 fig , ax = plt .subplots (2 )
@@ -6572,7 +6579,8 @@ def test_loglog():
65726579 ax .tick_params (length = 15 , width = 2 , which = 'minor' )
65736580
65746581
6575- @image_comparison (["test_loglog_nonpos.png" ], remove_text = True , style = 'mpl20' )
6582+ @image_comparison (["test_loglog_nonpos.png" ], remove_text = True , style = 'mpl20' ,
6583+ tol = 0.029 if platform .machine () == 'arm64' else 0 )
65766584def test_loglog_nonpos ():
65776585 fig , axs = plt .subplots (3 , 3 )
65786586 x = np .arange (1 , 11 )
@@ -7498,8 +7506,8 @@ def test_scatter_empty_data():
74987506 plt .scatter ([], [], s = [], c = [])
74997507
75007508
7501- @image_comparison (['annotate_across_transforms.png' ],
7502- style = 'mpl20' , remove_text = True )
7509+ @image_comparison (['annotate_across_transforms.png' ], style = 'mpl20' , remove_text = True ,
7510+ tol = 0.025 if platform . machine () == 'arm64' else 0 )
75037511def test_annotate_across_transforms ():
75047512 x = np .linspace (0 , 10 , 200 )
75057513 y = np .exp (- x ) * np .sin (x )
@@ -7529,7 +7537,8 @@ def inverted(self):
75297537 return _Translation (- self .dx )
75307538
75317539
7532- @image_comparison (['secondary_xy.png' ], style = 'mpl20' )
7540+ @image_comparison (['secondary_xy.png' ], style = 'mpl20' ,
7541+ tol = 0.027 if platform .machine () == 'arm64' else 0 )
75337542def test_secondary_xy ():
75347543 fig , axs = plt .subplots (1 , 2 , figsize = (10 , 5 ), constrained_layout = True )
75357544
@@ -8785,7 +8794,8 @@ def test_zorder_and_explicit_rasterization():
87858794 fig .savefig (b , format = 'pdf' )
87868795
87878796
8788- @image_comparison (["preset_clip_paths.png" ], remove_text = True , style = "mpl20" )
8797+ @image_comparison (["preset_clip_paths.png" ], remove_text = True , style = "mpl20" ,
8798+ tol = 0.027 if platform .machine () == "arm64" else 0 )
87898799def test_preset_clip_paths ():
87908800 fig , ax = plt .subplots ()
87918801
0 commit comments