STDP-Dataset / README.md
bfz111's picture
Use fresh anonymous download URLs for the sanitized release
08b6404 verified
|
Raw History Blame Contribute Delete
11 kB
---
license: mit
language:
- en
pretty_name: STDP Dataset
tags:
- robotics
- visual-navigation
- trajectory-planning
- unmanned-aerial-vehicles
- signal-temporal-logic
---
# STDP Dataset
This repository provides the data used to train, validate, and evaluate Signal
Temporal Logic-Guided Diffusion Policy (STDP) for UAV Visual Navigation without
Global Semantic Maps.
## Dataset Contents
Each trajectory sample combines a temporal-logic navigation instruction,
multi-view visual observations, and a reference motion trajectory.
| Component | Contents | Intended use |
|---|---|---|
| Semantic STL specification | Object-level temporal and logical constraints | Defines the navigation task presented to the policy |
| Coordinate-grounded STL specification | The same specification with object references mapped to XYZ coordinates | Supports supervision, analysis, and geometry-aware evaluation |
| Multi-view RGB observations | Synchronized front, down, left, and right camera images | Provides local visual context without a task-level global semantic map |
| Reference trajectory | CSV records containing absolute XYZ positions, camera yaw, frame indices, and image filenames | Supplies waypoint supervision and synchronizes motion with observations |
| Split manifests | JSONL records linking instructions, scenes, trajectories, and image directories | Defines the released training, validation, and evaluation subsets |
| Trajectory archives | One tar archive per trajectory | Enables selective downloading while preserving the original directory layout |
| Simulation environment | Four Gazebo Classic worlds, drone and base models, plugin source, materials, and capture scripts | Supports rebuilding the scenes and replaying trajectories |
## Scenes and Task Types
The data covers four furnished indoor scenes. `world_v1` is the primary scene
used by the training, validation, and same-scene evaluation splits.
`world_v2`, `world_v3`, and `world_v4` provide different indoor layouts for
cross-layout evaluation.
The released trajectories cover four task families:
| Task type | Objective |
|---|---|
| Reach-Avoid | Reach a specified target while avoiding constrained regions |
| Multi-Target | Visit multiple targets under temporal and logical constraints |
| Either-Or | Satisfy one of multiple valid target alternatives |
| Door Puzzle | Obey ordered reachability and avoidance requirements |
## Data Splits
| Manifest | Purpose |
|---|---|
| `splits/train.jsonl` | Stage 1 policy training in the primary scene |
| `splits/validation.jsonl` | Model selection and validation in the primary scene |
| `splits/test_same.jsonl` | Evaluation on held-out trajectories from the primary scene |
| `splits/test_cross.jsonl` | Evaluation in the three cross-layout scenes |
Each line in a split manifest is a JSON object with the following main fields:
| Field | Description |
|---|---|
| `task_type` | Navigation task family |
| `stl` | Semantic STL specification |
| `world` | Scene identifier |
| `trajectory_name` | Unique trajectory name within a scene |
| `trajectory_path` | Repository-relative path to the reference CSV after extraction |
| `images` | Repository-relative paths to the four camera directories after extraction |
## Repository Layout
```text
README.md
LICENSE
simulation_environment.tar.gz
simulation_environment.tar.gz.sha256
simulation/
README.md
world/home_room_v{1,2,3,4}.world
models/{simple_drone,sun,ground_plane}/
plugins/{SimpleDronePlugin.cc,CMakeLists.txt}
media/materials/{scripts,textures}/
build.sh
run.sh
gazebo_env.sh
datasets_construct.sh
smoke.sh
examples/smoke.csv
ENVIRONMENT.txt
VALIDATION.md
SOURCE_FILES.json
SHA256SUMS
validation/
splits/
train.jsonl
validation.jsonl
test_same.jsonl
test_cross.jsonl
archives/
world_v1/<trajectory_name>.tar
world_v2/<trajectory_name>.tar
world_v3/<trajectory_name>.tar
world_v4/<trajectory_name>.tar
```
Each trajectory archive contains the CSV and all synchronized images using the
original repository-relative paths. For example:
```text
data/world_v1/trajectory/trajectory_0127_01.csv
data/world_v1/images/trajectory_0127_01/images_front/
data/world_v1/images/trajectory_0127_01/images_down/
data/world_v1/images/trajectory_0127_01/images_left/
data/world_v1/images/trajectory_0127_01/images_right/
```
## Usage
Download files through the anonymous dataset endpoint. Install the HTTP client:
```bash
pip install requests
```
The following example downloads one split and its first trajectory archive:
```python
import json
from pathlib import Path
import requests
BASE_URL = "https://anonymous-hf.com/api/a/h8or94tutz4u/resolve/"
DATASET_ROOT = Path("STDP-Dataset")
def download(relative_path):
destination = DATASET_ROOT / relative_path
destination.parent.mkdir(parents=True, exist_ok=True)
partial = destination.with_name(destination.name + ".partial")
with requests.get(BASE_URL + relative_path, params={"release": "anonymous-20260929-complete"}, stream=True, timeout=120) as response:
response.raise_for_status()
with partial.open("wb") as output:
for chunk in response.iter_content(chunk_size=1024 * 1024):
output.write(chunk)
partial.replace(destination)
return destination
manifest = download("splits/test_same.jsonl")
with manifest.open(encoding="utf-8") as stream:
sample = json.loads(next(stream))
archive = download(
f"archives/{sample['world']}/{sample['trajectory_name']}.tar"
)
print(archive)
```
Extract the archive from the root of the local dataset directory:
```bash
tar -xf STDP-Dataset/archives/world_v1/trajectory_0587_05.tar -C STDP-Dataset
```
After extraction, `trajectory_path` and the four entries in `images` resolve
relative to `STDP-Dataset/`.
For all released trajectories, use the helper above to download the four split
manifests and their unique archives. This downloads approximately 145 GiB:
```python
archives = set()
for split in ("train", "validation", "test_same", "test_cross"):
manifest = download(f"splits/{split}.jsonl")
with manifest.open(encoding="utf-8") as stream:
for line in stream:
sample = json.loads(line)
archives.add(
f"archives/{sample['world']}/{sample['trajectory_name']}.tar"
)
for relative_path in sorted(archives):
download(relative_path)
```
## Simulation Environment
The simulation release includes all four indoor worlds, the drone's four-view
camera model, `SimpleDronePlugin` source and CMake configuration, base models,
custom materials and their textures, and build/playback/capture scripts.
- [Download the environment archive](https://anonymous-hf.com/api/a/h8or94tutz4u/resolve/simulation_environment.tar.gz?release=anonymous-20260929-complete)
- [Download its SHA256 checksum](https://anonymous-hf.com/api/a/h8or94tutz4u/resolve/simulation_environment.tar.gz.sha256?release=anonymous-20260929-complete)
- [Browse the dataset files](https://anonymous-hf.com/a/h8or94tutz4u/) (open `simulation/`)
- [Read the detailed setup guide](simulation/README.md)
- [Read the validation record](simulation/VALIDATION.md)
### Download and Build
Download just the environment without the trajectory archives:
Using the `download` helper from the Usage section:
```python
for filename in (
"simulation_environment.tar.gz",
"simulation_environment.tar.gz.sha256",
):
download(filename)
```
The reference platform is **Ubuntu 20.04.6 LTS and Gazebo Classic 11.15.1**.
The plugin uses the Gazebo C++ API directly and does not require ROS or PX4.
It is not compatible with the newer Gazebo simulator's `gz sim` command.
On Ubuntu 20.04 with a Gazebo 11 package source configured:
```bash
sudo apt-get update
sudo apt-get install gazebo11 libgazebo11-dev build-essential cmake pkg-config \
python3 python3-numpy python3-pil xvfb x11-utils mesa-utils pciutils
cd STDP-Dataset
sha256sum -c simulation_environment.tar.gz.sha256
tar -xzf simulation_environment.tar.gz
cd simulation_environment
sha256sum -c SHA256SUMS
chmod +x *.sh
bash build.sh
```
Run the build in a system Bash shell, preferably after leaving Conda. The plugin
is compiled locally to `plugins/build/libSimpleDronePlugin.so`; machine-specific
binaries and CMake caches are excluded from the release. If `gazebo11` has no
installation candidate, configure an appropriate Gazebo Classic package source
first. A full repository download also includes the same unpacked files under
`simulation/`; you can build from that directory instead.
### Check Rendering and Replay Released Trajectories
From the environment directory, run a one-waypoint capture check:
```bash
SIMPLE_DRONE_RENDER_BACKEND=xvfb bash smoke.sh v1
```
Use `v2`, `v3`, or `v4` to select another scene. Success prints `PASS` and creates
four 640 x 480 images plus capture metadata in `datasets/smoke_world_vN/`.
Even `gzserver` requires an OpenGL/X rendering context for camera sensors.
Software rendering can be slow; adjust `SIMPLE_DRONE_RUN_TIMEOUT` if needed.
To replay a trajectory downloaded and extracted using the instructions above,
copy its CSV into the matching scene directory. For example, from the environment
directory, with the dataset root one level above the environment directory:
```bash
mkdir -p datasets/world_v1/trajectory
cp ../data/world_v1/trajectory/trajectory_0127_01.csv \
datasets/world_v1/trajectory/
SIMPLE_DRONE_QUIT_ON_FINISH=1 ./run.sh v1 trajectory_0127_01.csv
```
Use a working copy: capture updates the input CSV in place with frame indices,
captured yaw, and image filenames. Images are written under
`datasets/world_v1/images/trajectory_0127_01/images_{front,down,left,right}/`.
For batch capture, run `./datasets_construct.sh datasets/world_v1`.
### Validation Scope
All four worlds passed resource and structural checks, and the plugin compiled
successfully from source on the reference system. The v1 smoke check passed image
quality validation and produced all four views. Under Xvfb, the plugin used its
existing single-camera sweep fallback after rejecting physical camera frames;
this is not a claim that all four physical cameras captured successfully without
fallback. Runtime capture in v2/v3/v4, installation on a separate clean machine,
and full benchmark reproduction were not validated for this release.
This package reproduces the simulation assets and playback/capture setup.
Training, trajectory planning, policy inference, and paper metrics additionally
require the main project code and data. Exact system versions, file provenance,
checksums, and build/capture logs are included with the environment.
## License
The dataset is released under the MIT License. See `LICENSE` for details.
Bundled third-party Gazebo base models and textures remain subject to their
upstream licenses and are not relicensed by the dataset license. Their sources
are recorded in [simulation/SOURCE_FILES.json](simulation/SOURCE_FILES.json).
## Citation
Coming soon.