pjm-data / crop_params /README.md
Lowca's picture
crop_params: link the pipeline step
c7138a3 verified
|
Raw History Blame Contribute Delete
839 Bytes
# Crop parameters
One square crop box per clip that frames the signer, found by running a YOLO person detector on every frame
(code: [pjm-data, step 05](https://github.com/crocosign/pjm-data/tree/main/dataset-processing/05_crop_params)). The videos are stored uncropped; the crop is
applied when loading data.
- `crop_params.lmdb/`: LMDB with the clip key (the `__key__` of the segment record) as key and a msgpack map as
value: `x_start`, `y_start`, `x_end`, `y_end` and `padding` (`top`, `bottom`, `left`, `right`). It covers all
39,813 segments, before the dataset filters.
- `failed.csv`: the 4 clips that could not be opened (`video_name`, `exception`).
```python
import lmdb, msgpack
env = lmdb.open("crop_params.lmdb", readonly=True, lock=False)
with env.begin() as txn:
box = msgpack.unpackb(txn.get(b"001_000_M"))
```