Feature Extraction
Transformers
Safetensors
j3pa
lidar
point-cloud
self-supervised-learning
autonomous-driving
custom_code
Instructions to use Zenseact/j3pa-tiny with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Zenseact/j3pa-tiny with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("feature-extraction", model="Zenseact/j3pa-tiny", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Zenseact/j3pa-tiny", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 4,421 Bytes
8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b e2786aa 89b1b2b 8b003e4 89b1b2b 8b003e4 0dbef27 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b e2786aa 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 8b003e4 89b1b2b 0dbef27 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 | ---
license: apache-2.0
library_name: transformers
base_model: Zenseact/j3pa-1b
tags:
- lidar
- point-cloud
- self-supervised-learning
- autonomous-driving
---
# J3PA-Tiny
J3PA is a family of self-supervised LiDAR point cloud encoders from Zenseact. They produce general-purpose features for
every point of a LiDAR scan, for downstream tasks such as semantic or panoptic segmentation and 3D object detection, and
can be used either frozen or fine-tuned. J3PA-Tiny is distilled from J3PA-1B and, like the other distilled models, takes the
voxel size as an input, so one model serves voxel sizes from 4 to 20 cm. Larger voxel sizes result in higher throughput at only a minor cost in downstream task performance.
See our paper for more details.
[Paper](https://arxiv.org/abs/2611.35165) · [Code](https://github.com/PaulineNasslander/J3PA)
## Model family
| Model | Parameters |
|---|---|
| **[J3PA-Tiny](https://huggingface.co/Zenseact/j3pa-tiny)** | **9.8M** |
| [J3PA-Small](https://huggingface.co/Zenseact/j3pa-small) | 42.4M |
| [J3PA-Large](https://huggingface.co/Zenseact/j3pa-large) | 134.6M |
| [J3PA-1B](https://huggingface.co/Zenseact/j3pa-1b) | 1.01B |
## How to use
The model runs custom GPU kernels that ship with this repository, so loading needs `trust_remote_code=True`.
Usage example:
```python
import numpy as np
import torch
from transformers import AutoModel
model = AutoModel.from_pretrained("Zenseact/j3pa-tiny", trust_remote_code=True, revision="v1.0").cuda()
# A nuScenes sweep: x, y, z, intensity, ring index -> [age, x, y, z, intensity].
xyzi = np.fromfile("n015-...__LIDAR_TOP__....pcd.bin", dtype=np.float32).reshape(-1, 5)[:, :4]
points = torch.from_numpy(np.concatenate([np.zeros((len(xyzi), 1), np.float32), xyzi], axis=1)).cuda()
with torch.inference_mode():
out = model(points)
features = out.point_features() # (N, 896): one feature per input point
```
**Batches.** Pass a list of point clouds and split the features back per cloud:
```python
with torch.inference_mode():
out = model([cloud_a, cloud_b])
features_a, features_b = out.point_features().split([len(cloud_a), len(cloud_b)])
```
**Voxel size.** `voxel_size` is the voxel size of the first encoder stage in meters, 0.05 by default. J3PA-Tiny was
trained with 4 to 20 cm. Use a float for all clouds or a tensor with one value per cloud:
```python
out = model(points, voxel_size=0.1)
out = model([cloud_a, cloud_b], voxel_size=torch.tensor([0.05, 0.1], device="cuda"))
```
## Input
One float32 CUDA tensor of shape (N, 5) per point cloud, with columns:
- **age:** seconds from the point's sweep to the newest sweep of the cloud (0 for a single sweep). Stack several sweeps
into one cloud by concatenating their points with their ages.
- **x, y, z:** meters, with x pointing forward, y left and z up.
- **intensity:** 0 to 255. Multiply sensors' 0–1 intensities by 255.
## Output
The encoder voxelizes the points and processes them in five stages, the voxels of stage s being 2^s times the voxel
size. The output gives:
- `point_features(stages=None)`: one feature per input point, in input order. By default the features of the point's
voxels in all five stages are concatenated, the deepest stage first: 256 + 256 + 192 + 128 + 64 = 896 channels,
as in our linear-probing evaluation. `point_features(0)` gives only the finest stage (64 channels).
`point_features([0, -1])` gives a chosen list of stages, negative indices counting from the deepest.
- `voxel_features(stages=None)`: the same per voxel of the first stage, which is cheaper for dense tasks.
- Per stage s: `features[s]` (N_s, C_s), `positions[s]` (N_s, 3; the mean position of the points in each voxel),
`batch_indices[s]` and `up_indices[s]`.
## Fine-tuning
The model trains like any PyTorch module. In train mode it randomizes the order of the space-filling-curves making attention groups as in pretraining.
## License
Apache 2.0, see [LICENSE](LICENSE).
## Citation
```bibtex
@misc{nässlander2026j3papredictiveapproachselfsupervised,
title={J3PA: A Predictive Approach to Self-Supervised 3D Representation Learning on Point Clouds},
author={Pauline Nässlander and Willem Verbeke and Adam Lilja and Fredrik Kahl and Lars Hammarstrand},
year={2026},
eprint={2611.35165},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2611.35165},
}
```
|