+
     ]ia(  c                   s   R t ^ RIt^ RIt^ RIt^ RIHtHt ^ RIH	t
 ^ RIHt ^ RIHt ^RIHtHt ^RIHt ^RIHt  ! R R	]P,                  4      t ! R
 R]P,                  4      t ! R R]4      t ! R R]P2                  4      t ! R R4      t]P6                  ! ]R4      t]! ]! ]P:                  4      4      t]tR# )z/
An experimental support for curvilinear grid.
N)_apicbook)Path)host_axes_class_factory)	axislinesgrid_helper_curvelinear)
AxisArtist)ExtremeFinderSimplec                   s    ] tR t^tRtR# )FloatingAxisArtistHelper N)__name__
__module____qualname____firstlineno____static_attributes__r	       L/usr/lib64/python3.14/site-packages/mpl_toolkits/axisartist/floating_axes.pyr   r      s    r   r   c                   sH   a a ] tR t^t oRV 3R lltR tR tR tRtVt	V ;t
# )FixedAxisArtistHelperc           	     s  < VP                   P                  ! R.^,          !  w  rErg\        P                  ! \	        V^ 3V^ 3V^3V^3R7      VR7      w  r\
        S
V `  WWR7       Vf   T	pW0n        Wn        Wn	        W n
        R# )ze
nth_coord = along which coordinate value varies.
 nth_coord = 0 ->  x axis, nth_coord = 1 -> y axis
NZleftZrightbottomZtop)sideaxis_direction)grid_finderextreme_finderr    Zcheck_getitemdictsuper__init__nth_coord_ticksvaluegrid_helper_side)selfr   r   r   Zlon1Zlon2Zlat1Zlat2r   	nth_coord	__class__s   &&&&      r   r   ZFixedAxisArtistHelper.__init__   s    
 "-!8!8!G!G$RS!TD--tQiay$q	R 	L"'O.
&
r   c                sr    V P                   P                  V4       V P                   P                  V n        R # N)r   
update_lim
_grid_info)r    axes   &&r   r$   Z FixedAxisArtistHelper.update_lim1   s)    ##D)**55r   c                s"  aaaaaaaaa  V P                   P                  oV P                  R,          w  r#pW$,          pV P                  R,          w  rgpWh,          p	V P                   P                  P                  ! R.^,          !  p
\	        V
R,          4      w  r\	        V
R,          4      w  rVV3R lpV P
                  ^ 8X  d[   W8*  W^8*  ,          p\        P                  ! WP                  VV,          W3W34      w  w  oo w  ppw  ppV P                  R,          oMjV P
                  ^8X  dZ   W8*  W8*  ,          p\        P                  ! WV,          V P                  W3W34      w  w  oo w  ppw  ppV P                  R,          o\        SX4       UUu. uF  w  ppV'       g   K  VNK  	  uppo\        P                  ! XX4      o\        P                  ! XX4      oV^ 8H  V^ 8H  ,          pSV,          \        P                  ^,          ,           SV&   V P                  S4      SP                  ,
          o\        P                   ! \"        P$                  P&                  R
4      oVVVVVVV 3R	 lpV! 4       \)        . 4      3# u uppi )z9tick_loc, tick_angle, tick_label, (optionally) tick_labellat_infolon_infoNN   Nr+   NNc                 s   < SP                  4       SP                  ,           pVP                  \        P                  ! \        P
                  ! W4      4      4      P                  # r#   )get_transform	transData	transformnpcolumn_stackZbroadcast_arraysZT)xyZtrfr&   r   s   && r   trf_xyZ8FixedAxisArtistHelper.get_tick_iterators.<locals>.trf_xyD   sC    ++->C==1D1DQ1J!KLNNNr   
lat_labels
lon_labelsc               3   s  <"   \        SSSSS	4       Fg  w  rr#pS
P                  W34      pS! V^ ,          4      '       g   K0  S! V^,          4      '       g   KG  W..\        P                  ! W#.4      OVN5x  Ki  	  R# 5i)    N)zipr/   r0   Zrad2deg)r2   r3   ZnormalZtangentZlabZc2angle_normalangle_tangentin_01labelstick_to_axesxx1yy1s         r   f1Z4FixedAxisArtistHelper.get_tick_iterators.<locals>.f1a   ss     3\=&I +fs!++QF3A<<E"Q%LL&E2::v.?#@E#EE Js   ;B B &B )r7      )r   r   r%   r   sortedr!   r   Z_value_and_jacobianr   r8   r0   Zarctan2ZpiZget_tick_transform	transAxes	functoolsZpartialmplZ
transformsZ_interval_contains_closeZiter)!r    r&   lat_levslat_n
lat_factorZyy0lon_levslon_n
lon_factorZxx0extremesxminxmaxyminymaxr4   ZmaskZdxx1Zdyy1Zdxx2Zdyy2ZlZmZmmr@   r9   r:   r   r;   r<   r=   r>   r?   s!   &f                       @@@@@@@@r   get_tick_iteratorsZ(FixedAxisArtistHelper.get_tick_iterators5   s/    &&22&*ooj&A##&*ooj&A####//>>
KHRL)
HRL)
	O >>QKCK0D';;JJD	D<$O 3JS#tltT __\2F^^q KCK0D';;ItzzD<$O 3JS#tltT __\2F #FD 17 11Q!! 17zz$-

4.aiDAI&(,ruuqy8R..t4t~~E!!NN33V=	F 	F tT"X~% 8s   J-Jc                s    V P                  V4       \        RRRRR7      V P                  ,          w  r#V P                  V,          V,          w  rE\	        \
        P                  ! WE.4      4      # )
lon_lines0r   )rR   r7   )rR   rA   )
lat_lines0r7   )rS   rA   )r$   r   r   r%   r   r0   r1   )r    r&   ZkZvZxxZyys   &&    r   get_lineZFixedAxisArtistHelper.get_linej   sa    *+,)+ ,0::7 #A&BOORH-..r   )r%   r   r   r   r   r#   )r
   r   r   r   r   r$   rQ   rT   r   __classdictcell____classcell__r"   __classdict__   @@r   r   r      s     $63j/ /r   r   c                   s,   a  ] tR t^tt o R tR tRtV tR# )ExtremeFinderFixedc                s    Wn         R# )z
This subclass always returns the same bounding box.

Parameters
----------
extremes : (float, float, float, float)
    The bounding box that this helper always returns.
NZ	_extremes)r    rL   r'   r   r   ZExtremeFinderFixed.__init__w   s	     "r   c                s    V P                   # r#   r[   )r    Ztransform_xyx1y1x2y2s   &&&&&&r   __call__ZExtremeFinderFixed.__call__   s    ~~r   r[   N)r
   r   r   r   r   r`   r   rU   )rX   s   @r   rZ   rZ   t   s     	" r   rZ   c                   sP   a a ] tR t^t oRV 3R lltRR ltR tRR ltRtVt	V ;t
# )GridHelperCurveLinearc           	     sD   < \         SV `  V\        V4      VVVVR 7       R# ))r   grid_locator1grid_locator2tick_formatter1tick_formatter2N)r   r   rZ   )r    Z	aux_transrL   rb   rc   rd   re   r"   s   &&&&&&&r   r   ZGridHelperCurveLinear.__init__   s-     	(:8(D'4'4)8)8 	 	:r   c                s    Vf   V P                   pVf   Tp\        WVR7      p\        WVVR7      pVP                  P	                  R4       VP                  P                  VP                   P                  4       V# )N)r   r   T)r&   r   r   ZlineZset_clip_onZset_clip_boxbbox)r    Zlocr!   r   Zoffsetr&   ZhelperZaxislines   &&&&&&  r   new_fixed_axisZ$GridHelperCurveLinear.new_fixed_axis   sk    <99D! N 'y2d>J!!$'""8==#5#56r   c                sL   V P                   f   \        4       V n         V P                   pV P                  pVP                  VP                  WW44      p\        VR,          4      w  r\        VR,          4      w  rWW3VR&   VP                  W4      w  rp\        P                  ! V4      pVP                  W4      w  ppp\        P                  ! V4      pWV3VR&   VVV3VR&   VP                  ^RW4      VR&   VP                  ^RVV4      VR&   VR V V,          pVR V V,          pVP                  VVV8  VV	8  ,          ,          VV
V8  VV8  ,          ,          WW4      w  ppVVR	&   VVR
&   VP                  ! VR,          VR,          .VO5!  w  ppVVR&   VVR&   R # )Nr*   r,   rL   r)   r(   r   r6   r5   	lon_lines	lat_linesrR   rS   )r%   r   r   r   Zinv_transform_xyrB   rb   r0   Zasarrayrc   Z_format_ticksZ_get_raw_grid_lines)r    r\   r]   r^   r_   Z	grid_infor   rL   Zlon_minZlon_maxZlat_minZlat_maxrI   rJ   rK   rF   rG   rH   Z
lon_valuesZ
lat_valuesrh   ri   s   &&&&&                 r   _update_gridZ"GridHelperCurveLinear._update_grid   s   ??""fDOOO	&&--k.J.J.0b> "(2,/!(2,/ '' B	* %%g7 	$::h'%%g7 	$%::h' ( ;	* (% ;	*"-";";x#/	,"-";";xX#/	, fu%
2
fu%
2
*>>*,g1EFG*,g1EFGg 0	9
 "+	+!*	+*>>RL(2, 3)1 3	9 #,	,"+	,r   c                s    . pVR9   d#   VP                  V P                  R,          4       VR9   d#   VP                  V P                  R,          4       V# )bothrh   ri   )rk   r2   )rk   r3   )Zextendr%   )r    ZwhichZaxisZ
grid_liness   &&& r   get_gridlinesZ#GridHelperCurveLinear.get_gridlines   sK    
= dook:;= dook:;r   )r%   )NNNN)Zmajorrk   )r
   r   r   r   r   rg   rj   rl   r   rU   rV   rW   rY   r   ra   ra      s     :<-,^ r   ra   c                   sJ   a a ] tR t^t oV 3R ltR tV 3R ltR tRtVt	V ;t
# )FloatingAxesBasec               s   < \         P                  ! \        VR 7       \        SV `  ! VRV/VB  V P                  R4       R# ))r   r   g      ?N)r    Zcheck_isinstancera   r   r   Z
set_aspect)r    r   ZargsZkwargsr"   s   &$*,r   r   ZFloatingAxesBase.__init__   s7    3M$BKB6Br   c                s    V P                  4       P                  P                  ! R .^,          !  w  rr4\        P                  ! W3W#3W$3W3.4      p^dVP                  4       n        V# r#   )get_grid_helperr   r   mpatchesZPolygonget_pathZ_interpolation_steps)r    Zx0r\   Zy0r]   patchs   &     r   _gen_axes_patchZ FloatingAxesBase._gen_axes_patch   sa    --/;;JJTFUVJW  2(RHrh!IJ03-r   c                s  < \         SV `  4        V P                  P                  V P	                  4       P
                  P                  4       V P                  ,           4       \         SV `!  4       pVP                  V P                  R R7      4       VP                  V P                  4       V P                  P                  V4       V P                  P                  V4       V P                  4        R# )F)ZrootN)r   clearrq   Zset_transformrn   r   r-   r.   rr   Z
set_figureZ
get_figurerC   Zset_clip_pathZ	gridlinesadjust_axes_lim)r    Z
orig_patchr"   s   & r   rs   ZFloatingAxesBase.clear   s    

    "..<<>nn	
 W,.
doo5o9:  0

  ,$$Z0r   c                sf   V P                   P                  4       P                  V P                   P                  4       V P                  ,
          4      pVP                  R R 4      pV P                  VP                  VP                  4       V P                  VP                  VP                  4       R# )gRQ?N)rq   rp   Zget_extentsr-   r.   ZexpandedZset_xlimrM   rN   Zset_ylimrO   rP   )r    rf   s   & r   rt   Z FloatingAxesBase.adjust_axes_lim  sv    zz""$00JJ$$&79 }}T4(dii+dii+r   r	   )r
   r   r   r   r   rr   rs   rt   r   rU   rV   rW   rY   r   rm   rm      s     
, ,r   rm   z
Floating{}) Z__doc__rD   Znumpyr0   Z
matplotlibrE   r    r   Zmatplotlib.patchesZpatchesro   Zmatplotlib.pathr   Z%mpl_toolkits.axes_grid1.parasite_axesr   Z r   r   Zaxis_artistr   r   r   r   r   rZ   ra   rm   Z_make_class_factoryZfloatingaxes_class_factoryZAxesZFloatingAxesZFloatingSubplotr	   r   r   <module>ru      s       " %   I 0 # ,	88	
T/3LL T/n, &b3II bJ", ",J #667GV )*A)..*QRr   