File size: 5,097 Bytes
806d399 6be2ace 806d399 9bc03b9 806d399 6be2ace 806d399 6be2ace 806d399 6be2ace 806d399 6be2ace 806d399 6be2ace 9bc03b9 806d399 6be2ace 806d399 6be2ace 806d399 9bc03b9 6be2ace 806d399 6be2ace 806d399 9bc03b9 806d399 6be2ace 806d399 6be2ace 806d399 6be2ace 806d399 6be2ace 9bc03b9 806d399 0760ff5 806d399 | 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 | ---
library_name: pytorch
license: other
tags:
- bu_auto
- android
pipeline_tag: other
---

# StateTransformer: Optimized for Qualcomm Devices
StateTransformer is a transformer-based model designed for trajectory prediction in self-driving scenarios. It integrates rasterized map data, agent context, and temporal dynamics to generate accurate future trajectories.
This repository contains pre-exported model files optimized for Qualcomm® devices. You can use the [Qualcomm® AI Hub Models](https://github.com/qualcomm/ai-hub-models/blob/v0.59.0/src/qai_hub_models/models/statetransformer) library to export with custom configurations. More details on model performance across various devices, can be found [here](#performance-summary).
Qualcomm AI Hub Models uses [Qualcomm AI Hub Workbench](https://workbench.aihub.qualcomm.com) to compile, profile, and evaluate this model. [Sign up](https://myaccount.qualcomm.com/signup) to run these models on a hosted Qualcomm® device.
## Getting Started
There are two ways to deploy this model on your device:
### Option 1: Download Pre-Exported Models
Below are pre-exported model assets ready for deployment.
| Runtime | Precision | Chipset | SDK Versions | Download |
|---|---|---|---|---|
| ONNX | float | Universal | QAIRT 2.45, ONNX Runtime 1.27.1 | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/statetransformer/releases/v0.59.0/statetransformer-onnx-float.zip)
| TFLITE | float | Universal | | [Download](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/models/statetransformer/releases/v0.59.0/statetransformer-tflite-float.zip)
For more device-specific assets and performance metrics, visit **[StateTransformer on Qualcomm® AI Hub](https://aihub.qualcomm.com/models/statetransformer)**.
### Option 2: Export with Custom Configurations
Use the [Qualcomm® AI Hub Models](https://github.com/qualcomm/ai-hub-models/blob/v0.59.0/src/qai_hub_models/models/statetransformer) Python library to compile and export the model with your own:
- Custom weights (e.g., fine-tuned checkpoints)
- Custom input shapes
- Target device and runtime configurations
This option is ideal if you need to customize the model beyond the default configuration provided here.
See our repository for [StateTransformer on GitHub](https://github.com/qualcomm/ai-hub-models/blob/v0.59.0/src/qai_hub_models/models/statetransformer) for usage instructions.
## Model Details
**Model Type:** Model_use_case.driver_assistance
**Model Stats:**
- Model checkpoint: pretrained-mixtral-small
- Input resolution: 1x224x224x58, 1x224x224x58, 1x4x7
- Number of parameters: 90.7M
- Model size (float): 348 MB
## Performance Summary
| Model | Runtime | Precision | Chipset | Inference Time (ms) | Peak Memory Range (MB) | Primary Compute Unit
|---|---|---|---|---|---|---
| StateTransformer | ONNX | float | Snapdragon® 8 Gen 3 Mobile | 935.497 ms | 75 - 3989 MB | NPU
| StateTransformer | ONNX | float | Qualcomm® Dragonwing™ Q-8750 | 771.09 ms | 89 - 3000 MB | NPU
| StateTransformer | ONNX | float | Snapdragon® 8 Elite Mobile | 771.09 ms | 89 - 3000 MB | NPU
| StateTransformer | TFLITE | float | Snapdragon® 8 Gen 3 Mobile | 493.767 ms | 308 - 326 MB | CPU
| StateTransformer | TFLITE | float | Snapdragon® 8 Gen 1 Mobile | 713.923 ms | 265 - 284 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® Dragonwing™ QCS8275 | 931.808 ms | 443 - 457 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® Dragonwing™ QCS8550 (Proxy) | 591.882 ms | 393 - 459 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® SA8775P | 735.722 ms | 448 - 460 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® SA8650P | 735.722 ms | 448 - 460 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® SA8255P | 735.722 ms | 448 - 460 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® QCS8450 | 713.923 ms | 265 - 284 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® Dragonwing™ IQ-9075 | 758.484 ms | 238 - 659 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® Dragonwing™ Q-8750 | 377.443 ms | 411 - 422 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® SA7255P | 931.808 ms | 443 - 457 MB | CPU
| StateTransformer | TFLITE | float | Qualcomm® SA8295P | 596.745 ms | 387 - 396 MB | CPU
| StateTransformer | TFLITE | float | Snapdragon® 8 Elite Mobile | 377.443 ms | 411 - 422 MB | CPU
| StateTransformer | TFLITE | float | Snapdragon® 8 Elite Gen 5 Mobile | 252.872 ms | 192 - 204 MB | CPU
## License
* The license for the original implementation of StateTransformer can be found
[here](https://github.com/Tsinghua-MARS-Lab/StateTransformer/blob/main/setup.py).
## Community
* Join [our AI Hub Slack community](https://aihub.qualcomm.com/community/slack) to collaborate, post questions and learn more about on-device AI.
* For questions or feedback please [reach out to us](mailto:ai-hub-support@qti.qualcomm.com).
|