@@ -304,7 +304,7 @@ def open_orbit_dataset(
304304 position = xr .Variable (data = data ["position" ], dims = ("axis" , "azimuth_time" )) # type: ignore
305305 velocity = xr .Variable (data = data ["velocity" ], dims = ("axis" , "azimuth_time" )) # type: ignore
306306
307- attrs = attrs | {}
307+ attrs = attrs . copy ()
308308 if reference_system is not None :
309309 attrs .update ({"reference_system" : reference_system })
310310
@@ -443,15 +443,18 @@ def open_pol_dataset(
443443 number_of_bursts = swath_timing ["burstList" ]["@count" ]
444444 range_pixel_spacing = image_information ["rangePixelSpacing" ]
445445
446- attrs = attrs | {
447- "radar_frequency" : product_information ["radarFrequency" ] / 10 ** 9 ,
448- "azimuth_pixel_spacing" : image_information ["azimuthPixelSpacing" ],
449- "range_pixel_spacing" : range_pixel_spacing ,
450- "azimuth_time_interval" : azimuth_time_interval ,
451- "range_sampling_rate" : range_sampling_rate ,
452- "incidence_angle_mid_swath" : image_information ["incidenceAngleMidSwath" ],
453- "ascending_node_time" : image_information ["ascendingNodeTime" ],
454- }
446+ attrs = attrs .copy ()
447+ attrs .update (
448+ {
449+ "radar_frequency" : product_information ["radarFrequency" ] / 10 ** 9 ,
450+ "azimuth_pixel_spacing" : image_information ["azimuthPixelSpacing" ],
451+ "range_pixel_spacing" : range_pixel_spacing ,
452+ "azimuth_time_interval" : azimuth_time_interval ,
453+ "range_sampling_rate" : range_sampling_rate ,
454+ "incidence_angle_mid_swath" : image_information ["incidenceAngleMidSwath" ],
455+ "ascending_node_time" : image_information ["ascendingNodeTime" ],
456+ }
457+ )
455458 encoding = {}
456459 swap_dims = {}
457460 chunks : T .Union [None , T .Dict [str , int ]] = None
0 commit comments