Datasets:
Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -1,3 +1,135 @@
|
|
| 1 |
-
---
|
| 2 |
-
|
| 3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
pretty_name: "NA-SAR"
|
| 3 |
+
tags:
|
| 4 |
+
- geospatial
|
| 5 |
+
- remote-sensing
|
| 6 |
+
- sar
|
| 7 |
+
- earth-observation
|
| 8 |
+
- self-supervised-learning
|
| 9 |
+
- pretraining
|
| 10 |
+
- webdataset
|
| 11 |
+
- pytorch
|
| 12 |
+
size_categories:
|
| 13 |
+
- 1M<n<10M
|
| 14 |
+
task_categories:
|
| 15 |
+
- image-feature-extraction
|
| 16 |
+
---
|
| 17 |
+
|
| 18 |
+
# NA-SAR
|
| 19 |
+
|
| 20 |
+
NA-SAR is a North America synthetic aperture radar pretraining dataset built
|
| 21 |
+
from the NASA OPERA archive. It is intended for self-supervised and masked-image
|
| 22 |
+
pretraining of SAR foundation models.
|
| 23 |
+
|
| 24 |
+
This release is an unsplit pretraining corpus. There are no train/validation/test
|
| 25 |
+
partitions because the dataset is not intended to define an evaluation protocol.
|
| 26 |
+
Downstream evaluations should define their own geographically and temporally
|
| 27 |
+
appropriate splits.
|
| 28 |
+
|
| 29 |
+
## Dataset Contents
|
| 30 |
+
|
| 31 |
+
- Samples: 1,099,604
|
| 32 |
+
- Patch size: 128 x 128 pixels
|
| 33 |
+
- RTC views: two spatial views per sample
|
| 34 |
+
- Temporal RTC acquisitions: prime and secondary
|
| 35 |
+
- RTC channels: co-pol and cross-pol, with missing polarization zero padded
|
| 36 |
+
- Incidence angle: one channel per spatial view
|
| 37 |
+
- InSAR phase: stored as cos(phi), sin(phi)
|
| 38 |
+
- Coherence: one channel per spatial view
|
| 39 |
+
|
| 40 |
+
Each tensor sample contains:
|
| 41 |
+
|
| 42 |
+
| Key | Shape | Description |
|
| 43 |
+
| --- | --- | --- |
|
| 44 |
+
| `prime_rtc_view_0` | `(2, 128, 128)` | Prime RTC view 0, co-pol/cross-pol |
|
| 45 |
+
| `secondary_rtc_view_0` | `(2, 128, 128)` | Secondary RTC view 0, co-pol/cross-pol |
|
| 46 |
+
| `prime_rtc_view_1` | `(2, 128, 128)` | Prime RTC view 1, co-pol/cross-pol |
|
| 47 |
+
| `secondary_rtc_view_1` | `(2, 128, 128)` | Secondary RTC view 1, co-pol/cross-pol |
|
| 48 |
+
| `inc_angle_view_0` | `(1, 128, 128)` | Incidence angle for view 0 |
|
| 49 |
+
| `inc_angle_view_1` | `(1, 128, 128)` | Incidence angle for view 1 |
|
| 50 |
+
| `ifg_view_0` | `(2, 128, 128)` | InSAR phase for view 0 as cos/sin |
|
| 51 |
+
| `coh_view_0` | `(1, 128, 128)` | Coherence for view 0 |
|
| 52 |
+
| `ifg_view_1` | `(2, 128, 128)` | InSAR phase for view 1 as cos/sin |
|
| 53 |
+
| `coh_view_1` | `(1, 128, 128)` | Coherence for view 1 |
|
| 54 |
+
|
| 55 |
+
## Metadata
|
| 56 |
+
|
| 57 |
+
`metadata_hf.parquet` is the publishable metadata table for the sharded release.
|
| 58 |
+
It includes OPERA provenance, patch geometry, quality score, polarization
|
| 59 |
+
availability, and the following sharding columns:
|
| 60 |
+
|
| 61 |
+
- `sample_key`: sample key inside the WebDataset shard
|
| 62 |
+
- `shard_path`: relative path to the tar shard
|
| 63 |
+
- `shard_index`: integer shard id
|
| 64 |
+
- `sample_index_in_shard`: row order within that shard
|
| 65 |
+
|
| 66 |
+
The metadata is filtered to samples with `quality_score > 0.53`.
|
| 67 |
+
|
| 68 |
+
## Loading With Hugging Face Datasets
|
| 69 |
+
|
| 70 |
+
The sharded release can be streamed with the WebDataset loader:
|
| 71 |
+
|
| 72 |
+
```python
|
| 73 |
+
from io import BytesIO
|
| 74 |
+
|
| 75 |
+
import numpy as np
|
| 76 |
+
from datasets import load_dataset
|
| 77 |
+
|
| 78 |
+
ds = load_dataset(
|
| 79 |
+
"webdataset",
|
| 80 |
+
data_files={"train": "data/nasar-train-*.tar"},
|
| 81 |
+
split="train",
|
| 82 |
+
streaming=True,
|
| 83 |
+
)
|
| 84 |
+
|
| 85 |
+
sample = next(iter(ds))
|
| 86 |
+
arrays = np.load(BytesIO(sample["npz"]))
|
| 87 |
+
print(arrays.files)
|
| 88 |
+
```
|
| 89 |
+
|
| 90 |
+
## Loading With PyTorch
|
| 91 |
+
|
| 92 |
+
The repository includes a lightweight PyTorch helper:
|
| 93 |
+
|
| 94 |
+
```python
|
| 95 |
+
from nasar_dataset import NASARRTCDataset, NASARInSARDataset
|
| 96 |
+
|
| 97 |
+
rtc_ds = NASARRTCDataset("/path/to/NA-SAR")
|
| 98 |
+
insar_ds = NASARInSARDataset("/path/to/NA-SAR")
|
| 99 |
+
```
|
| 100 |
+
|
| 101 |
+
For streaming at scale, use the WebDataset tar shards under `data/`.
|
| 102 |
+
Each tar member is a compressed `.npz` tensor file named `{sample_key}.npz`.
|
| 103 |
+
|
| 104 |
+
## Preprocessing Notes
|
| 105 |
+
|
| 106 |
+
RTC arrays are stored as raw linear backscatter with invalid, non-finite, and
|
| 107 |
+
negative values set to zero. The helper loader applies the pretraining-time RTC
|
| 108 |
+
transform by default:
|
| 109 |
+
|
| 110 |
+
```python
|
| 111 |
+
x = log1p(20.0 * x)
|
| 112 |
+
x = clip_and_rescale(x, p1=0.14, p99=2.38)
|
| 113 |
+
```
|
| 114 |
+
|
| 115 |
+
InSAR phase is stored as cosine and sine channels instead of wrapped phase
|
| 116 |
+
radians to avoid phase discontinuities at the wrap boundary.
|
| 117 |
+
|
| 118 |
+
## Source and Scope
|
| 119 |
+
|
| 120 |
+
The source data comes from OPERA SAR products over North America. Users should
|
| 121 |
+
follow the applicable terms and citation guidance for OPERA source products.
|
| 122 |
+
|
| 123 |
+
## Intended Use
|
| 124 |
+
|
| 125 |
+
This dataset is intended for SAR and InSAR representation learning, especially
|
| 126 |
+
self-supervised pretraining. It is not an evaluation benchmark by itself.
|
| 127 |
+
|
| 128 |
+
## Limitations
|
| 129 |
+
|
| 130 |
+
- Coverage is geographically focused on North America.
|
| 131 |
+
- Quality filtering removes lower-quality samples and can bias the corpus toward
|
| 132 |
+
easier or cleaner acquisitions.
|
| 133 |
+
- Missing RTC polarizations are represented by zero-padded channels. The
|
| 134 |
+
metadata includes polarization availability flags so users can distinguish
|
| 135 |
+
true zeros from missing channels.
|