@@ -23,7 +23,7 @@ Overall the software is in the **alpha** phase and the usual caveats apply.
23
23
satellite orbit and attitude, ground control points, radiometric calibration look up tables,
24
24
Doppler centroid estimation and more
25
25
- reads uncompressed and compressed SAFE data products on the local computer or
26
- on a network via [ * fsspec* ] ( https://filesystem-spec.readthedocs.io ) - ** dependes on rasterio>=1.3a3**
26
+ on a network via [ * fsspec* ] ( https://filesystem-spec.readthedocs.io ) - ** depends on rasterio>=1.3a3**
27
27
- supports larger-than-memory and distributed data access via [ * Dask* ] ( https://dask.org ) and
28
28
[ * rioxarray* ] ( https://corteva.github.io/rioxarray ) /
29
29
[ * rasterio* ] ( https://rasterio.readthedocs.io ) / [ * GDAL* ] ( https://gdal.org )
@@ -87,14 +87,14 @@ Attributes: ...
87
87
88
88
The root ` Dataset ` does not contain any data variable, but only attributes that provide general information
89
89
on the product and a description of the tree structure of the data.
90
- The attribute ` group ` contains the name of the current group and the ` subgroups ` attribute shows
90
+ The ` group ` attribute contains the name of the current group and the ` subgroups ` attribute shows
91
91
the names of all available groups below this one.
92
92
93
93
### Measurements datasets
94
94
95
95
To open the other groups we need to add the keyword ` group ` to ` xr.open_dataset ` .
96
- So we can read the measurement by selecting the desired beam mode and the polarization,
97
- in this example the data contains the S3 beam mode and we select the VH polarization with ` group="S3/VH" ` :
96
+ The measurement can then be read by selecting the desired beam mode and polarization.
97
+ In this example, the data contains the S3 beam mode and the VH polarization with ` group="S3/VH" ` is selected :
98
98
99
99
``` python-repl
100
100
>>> slc_s3_vh = xr.open_dataset(slc_sm_path, group="S3/VH", engine="sentinel-1", chunks=2048)
@@ -126,15 +126,15 @@ Attributes: ...
126
126
```
127
127
128
128
The ` measurement ` variable contains the Single Look Complex measurements as a ` complex64 `
129
- and it has dimensions ` slant_range_time ` and ` azimuth_time ` .
129
+ and has dimensions ` slant_range_time ` and ` azimuth_time ` .
130
130
The ` azimuth_time ` is an ` np.datetime64 ` coordinate that contains the UTC zero-Doppler time
131
131
associated with the image line
132
132
and ` slant_range_time ` is an ` np.float64 ` coordinate that contains the two-way range time interval
133
133
in seconds associated with the image pixel.
134
134
135
135
### Metadata datasets
136
136
137
- The measurement group contains several subgroups with metadata associated with the image, at the moment
137
+ The measurement group contains several subgroups with metadata associated with the image. Currently,
138
138
* xarray-sentinel* supports the following metadata datasets:
139
139
140
140
- product XML file
@@ -185,7 +185,7 @@ Attributes: ...
185
185
```
186
186
187
187
Note that in this case, the dimensions are ` line ` and ` pixel ` with coordinates corresponding to
188
- the sub-grid of the original image where it is defined the calibration Look Up Table.
188
+ the sub-grid of the original image where the calibration Look Up Table is defined .
189
189
190
190
The groups present in a typical Sentinel-1 Stripmap product are:
191
191
@@ -227,7 +227,7 @@ but also because the measurement array is a collage of sub-images called *bursts
227
227
228
228
You need to first open the desired measurement dataset, for example, the VH polarisation
229
229
of the first IW swath of the ` S1B_IW_SLC__1SDV_20210401T052622_20210401T052650_026269_032297_EFA4 `
230
- product in the current folder:
230
+ product, in the current folder:
231
231
232
232
``` python-repl
233
233
>>> slc_iw_path = "tests/data/S1B_IW_SLC__1SDV_20210401T052622_20210401T052650_026269_032297_EFA4.SAFE"
@@ -293,7 +293,7 @@ Attributes: ...
293
293
294
294
```
295
295
296
- Note that the helper function also performs additional changes like swapping the dimensions
296
+ Note that the helper function also performs additional changes, such as swapping the dimensions
297
297
to the physical coordinates and adding burst attributes.
298
298
299
299
As a quick way to access burst data, you can add the ` burst_index ` to the group specification on
@@ -352,15 +352,15 @@ Attributes:
352
352
353
353
** You need the unreleased rasterio>=1.3a3 for fsspec to work on measurement data**
354
354
355
- You can test the following after :
355
+ You can test with the following:
356
356
` pip install -U --pre --no-deps --no-binary rasterio rasterio>=1.3a3 ` .
357
357
358
358
* xarray-sentinel* can read data from a variety of data stores including local file systems,
359
359
network file systems, cloud object stores and compressed file formats, like Zip.
360
360
This is done by passing * fsspec* compatible URLs to ` xr.open_dataset ` and optionally
361
361
the ` storage_options ` keyword argument.
362
362
363
- For exmaple you can open a product directly from a Zip file with:
363
+ For example you can open a product directly from a zip file with:
364
364
365
365
``` python-repl
366
366
>>> slc_iw_zip_path = "tests/data/S1B_IW_SLC__1SDV_20210401T052622_20210401T052650_026269_032297_EFA4.zip"
@@ -391,7 +391,7 @@ Attributes: ...
391
391
392
392
```
393
393
394
- As an exmaple of remote access you can open a product directly from a GitHub repo with:
394
+ As an example of remote access, you can open a product directly from a GitHub repo with:
395
395
396
396
``` python-repl
397
397
>>> xr.open_dataset(f"github://bopen:xarray-sentinel@/{slc_iw_path}", group="IW1/VH", engine="sentinel-1") # doctest: +SKIP
@@ -461,36 +461,37 @@ Attributes: ...
461
461
462
462
## Design decisions
463
463
464
- - The main design choice for * xarray-sentinel* is for it to be as much as possible a pure map of
464
+ - The main design choice for * xarray-sentinel* is for it to be as much as viable a pure map of
465
465
the content of the SAFE data package, with as little interpretation as possible.
466
466
- The tree-like structure follows the structure of the SAFE package even when information,
467
467
like orbit and attitude, is expected to be identical for different beam modes.
468
468
We observed at least a case where the number of orbital state vectors reported
469
469
was different between beam modes.
470
470
- Data and metadata are converted to the closest available data-type in * Python* / * numpy* .
471
471
The most significant conversion is from ` CInt16 ` to ` np.complex64 ` for the SLC measurements
472
- that doubles the space requirements for the data.
472
+ that double the space requirements for the data.
473
473
Also, * xarray-sentinel* converts UTC times to ` np.datetime64 ` and makes no attempt to support
474
474
* leap seconds* , acquisitions containing leap seconds may crash or silently return corrupted data.
475
475
See the rationale for choices of the coordinates data-types below.
476
476
- We try to keep all naming as close as possible to the original names,
477
- in particular, for metadata we use the names of the XML tags, only converting them
478
- from * camelCase* to * snake_case* . Except for the high-level attributes, see below.
477
+ except for high-level attributes (see below).
478
+ In particular, for metadata we use the names of the XML tags, only converting them
479
+ from * camelCase* to * snake_case* .
479
480
- Whenever possible * xarray-sentinel* indexes the data with physical coordinates
480
481
` azimuth_time ` and ` slant_range_time ` , but keeps image ` line ` and ` pixel ` as auxiliary coordinates.
481
482
- As an exception to the metadata naming rule above for high-level attributes, we aim at
482
483
STAC Index and CF-Conventions compliance (in this order).
483
484
- We aim at opening available data and metadata even for partial SAFE packages, for example,
484
485
* xarray-sentinel* can open a measurement dataset for a beam mode even when the TIFF files of other
485
- beam modes / polarization are missing.
486
- - Accuracy considerations and rationale for the data-types of the coordinates
487
- - ` azimuth_time ` can be expressed as ` np.datetime64[ns] ` because
486
+ beam modes / polarizations are missing.
487
+ - Accuracy considerations and rationale for coordinates data-types:
488
+ - ` azimuth_time ` can be expressed as ` np.datetime64[ns] ` since
488
489
spatial resolution at LEO speed is 10km/s * 1ns ~ = 0.001cm.
489
- - ` slant_range_time ` on the other hand cannot be expressed as ` np.timedelta64[ns] ` because
490
+ - ` slant_range_time ` on the other hand cannot be expressed as ` np.timedelta64[ns] ` as
490
491
spatial resolution at the speed of light is 300_000km/s * 1ns / 2 ~ = 15cm,
491
- that it is not enough for interferometric applications.
492
- ` slant_range_time ` needs a spatial resolution of 0.001cm at a 1_000km distance
493
- so around 1e-9 that is well within 1e-15 resolution of IEEE-754 float64.
492
+ i.e. not enough for interferometric applications.
493
+ ` slant_range_time ` needs a spatial resolution of 0.001cm at a 1_000km distance,
494
+ i.e. around 1e-9, well within the 1e-15 resolution of IEEE-754 float64.
494
495
- This is a list of reference documents:
495
496
- Sentinel-1 document library - https://sentinels.copernicus.eu/web/sentinel/user-guides/sentinel-1-sar/document-library
496
497
- Sentinel-1 Product Specification v3.9 07 May 2021 S1-RS-MDA-52-7441-3-9 documenting IPF 3.40 -
@@ -508,8 +509,8 @@ Attributes: ...
508
509
509
510
## Contributing
510
511
511
- The main repository is hosted on GitHub,
512
- testing , bug reports and contributions are highly welcomed and appreciated:
512
+ The main repository is hosted on GitHub.
513
+ Testing , bug reports and contributions are highly welcomed and appreciated:
513
514
514
515
https://github.com/bopen/xarray-sentinel
515
516
@@ -530,7 +531,7 @@ See also the list of [contributors](https://github.com/bopen/xarray-sentinel/con
530
531
531
532
We wish to express our gratitude to the project sponsors:
532
533
533
- - [ Microsoft] ( https://microsoft.com ) has contributed to adding GRD products and * fsspec* access
534
+ - [ Microsoft] ( https://microsoft.com ) has contributed to adding GRD products and * fsspec* access.
534
535
535
536
## License
536
537
0 commit comments