added notebook. Fixed 4 npz files that were broken. Small updates overall.
Browse files- .gitignore +2 -0
- README.md +10 -2
- data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3565.npz +2 -2
- data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3570.npz +2 -2
- data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3582.npz +2 -2
- data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3592.npz +2 -2
- dronescapes_reader/multitask_dataset.py +3 -2
- dronescapes_viewer.ipynb +0 -0
.gitignore
CHANGED
|
@@ -9,4 +9,6 @@ copyfiles3.txt
|
|
| 9 |
raw_data/npz_540p
|
| 10 |
exception.txt
|
| 11 |
__pycache__
|
|
|
|
|
|
|
| 12 |
|
|
|
|
| 9 |
raw_data/npz_540p
|
| 10 |
exception.txt
|
| 11 |
__pycache__
|
| 12 |
+
error.txt
|
| 13 |
+
sanity_check.py
|
| 14 |
|
README.md
CHANGED
|
@@ -189,11 +189,19 @@ Basic usage:
|
|
| 189 |
'semantic_segprop8': torch.Size([5, 540, 960])}
|
| 190 |
```
|
| 191 |
|
| 192 |
-
</
|
| 193 |
|
| 194 |
## TODOs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 195 |
- mask2former convert
|
| 196 |
- add raw script for reading data
|
| 197 |
- add semantics for each representation in a DronescapesReader
|
| 198 |
- add notebook for visualisation
|
| 199 |
-
- push to huggingface dataset
|
|
|
|
| 189 |
'semantic_segprop8': torch.Size([5, 540, 960])}
|
| 190 |
```
|
| 191 |
|
| 192 |
+
</details>
|
| 193 |
|
| 194 |
## TODOs
|
| 195 |
+
- Fix remaining bad npz files
|
| 196 |
+
```
|
| 197 |
+
/scratch/sdc/datasets/dronescapes/data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3565.npz
|
| 198 |
+
/scratch/sdc/datasets/dronescapes/data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3570.npz
|
| 199 |
+
/scratch/sdc/datasets/dronescapes/data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3582.npz
|
| 200 |
+
/scratch/sdc/datasets/dronescapes/data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3592.npz
|
| 201 |
+
```
|
| 202 |
+
|
| 203 |
+
- convert camera normals to world normals
|
| 204 |
- mask2former convert
|
| 205 |
- add raw script for reading data
|
| 206 |
- add semantics for each representation in a DronescapesReader
|
| 207 |
- add notebook for visualisation
|
|
|
data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3565.npz
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9f0f4de75392b21d1a4dc0df1ea964e8151ccbe929790e1538cb0ae1f96a8fd6
|
| 3 |
+
size 2073864
|
data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3570.npz
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0ab9ca4ac88fd68f28f36ce7cffaa5b813b6c894d525292a36240cb9e0ff0032
|
| 3 |
+
size 2073864
|
data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3582.npz
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:87797811c59b4ddaa5a404a88f91728b11810d6faccfafc231457af8feef9658
|
| 3 |
+
size 2073864
|
data/semisupervised_set/depth_dpt/part0/herculane_DJI_0021_full_3592.npz
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:3c8eb3bc06c9e7dd3e18c3c27b37ab182f866ef295e64119e4faf4a5f3fabe76
|
| 3 |
+
size 2073864
|
dronescapes_reader/multitask_dataset.py
CHANGED
|
@@ -38,7 +38,8 @@ class NpzRepresentation:
|
|
| 38 |
if x.shape[-1] != 3: x = x[..., 0:1]
|
| 39 |
if x.shape[-1] == 1: x = x.repeat(1, 1, 3)
|
| 40 |
x = x.nan_to_num(0).cpu().numpy() # guaranteed to be (H, W, 3) at this point hopefully
|
| 41 |
-
|
|
|
|
| 42 |
return x
|
| 43 |
|
| 44 |
def __repr__(self):
|
|
@@ -69,7 +70,7 @@ class MultiTaskDataset(Dataset):
|
|
| 69 |
|
| 70 |
def __init__(self, path: Path, task_names: list[str] | None = None, handle_missing_data: str = "fill_none",
|
| 71 |
files_suffix: str = "npz"):
|
| 72 |
-
assert path.exists(), f"Provided path '{path}' doesn't exist!"
|
| 73 |
assert handle_missing_data in ("drop", "fill_none"), f"Invalid handle_missing_data mode: {handle_missing_data}"
|
| 74 |
assert files_suffix == "npz", "Only npz supported right now (though trivial to update)"
|
| 75 |
self.path = Path(path).absolute()
|
|
|
|
| 38 |
if x.shape[-1] != 3: x = x[..., 0:1]
|
| 39 |
if x.shape[-1] == 1: x = x.repeat(1, 1, 3)
|
| 40 |
x = x.nan_to_num(0).cpu().numpy() # guaranteed to be (H, W, 3) at this point hopefully
|
| 41 |
+
_min, _max = x.min((0, 1), keepdims=True), x.max((0, 1), keepdims=True)
|
| 42 |
+
if x.dtype != np.uint8: x = np.nan_to_num((x - _min) / (_max - _min) * 255, 0).astype(np.uint8)
|
| 43 |
return x
|
| 44 |
|
| 45 |
def __repr__(self):
|
|
|
|
| 70 |
|
| 71 |
def __init__(self, path: Path, task_names: list[str] | None = None, handle_missing_data: str = "fill_none",
|
| 72 |
files_suffix: str = "npz"):
|
| 73 |
+
assert Path(path).exists(), f"Provided path '{path}' doesn't exist!"
|
| 74 |
assert handle_missing_data in ("drop", "fill_none"), f"Invalid handle_missing_data mode: {handle_missing_data}"
|
| 75 |
assert files_suffix == "npz", "Only npz supported right now (though trivial to update)"
|
| 76 |
self.path = Path(path).absolute()
|
dronescapes_viewer.ipynb
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|