| --- |
| license: mit |
| language: |
| - en |
| library_name: pytorch |
| tags: |
| - computer-vision |
| - autonomous-driving |
| - self-driving |
| - interfuser |
| - carla |
| - object-detection |
| - trajectory-prediction |
| datasets: |
| - PDM-Lite-CARLA |
| pipeline_tag: object-detection |
| --- |
| |
| # ๐ InterFuser-Baseer-v1: Autonomous Driving Model |
|
|
| [](https://opensource.org/licenses/MIT) |
| [](https://pytorch.org/) |
| [](https://carla.org/) |
| [](https://huggingface.co/spaces/BaseerAI/Baseer_Server) |
|
|
| > **๐ฎ [Try the Live Demo](https://huggingface.co/spaces/BaseerAI/Baseer_Server)** - Experience the model in action with real-time autonomous driving simulation! |
|
|
| ## ๐ Overview |
|
|
| InterFuser-Baseer-v1 is a state-of-the-art transformer-based model for autonomous driving, specifically fine-tuned for the **[Baseer Self-Driving API](https://huggingface.co/spaces/BaseerAI/Baseer_Server)**. This model combines computer vision and deep learning to provide real-time traffic object detection and trajectory planning in simulated driving environments. |
|
|
| ### ๐ฏ Key Capabilities |
|
|
| - **Multi-Task Learning**: Simultaneous traffic object detection and waypoint prediction |
| - **Transformer Architecture**: Advanced attention mechanisms for scene understanding |
| - **Real-Time Processing**: Optimized for real-time inference in driving scenarios |
| - **CARLA Integration**: Specifically tuned for CARLA simulation environment |
|
|
| ## ๐๏ธ Architecture |
|
|
| ### Model Components |
|
|
| | Component | Specification | |
| |-----------|---------------| |
| | **Image Backbone** | ResNet-50 (ImageNet pretrained) | |
| | **LiDAR Backbone** | ResNet-18 (disabled in this version) | |
| | **Transformer** | 6-layer encoder/decoder, 8 attention heads | |
| | **Embedding Dimension** | 256 | |
| | **Prediction Heads** | GRU-based waypoint predictor + Detection head | |
|
|
| ### Output Format |
|
|
| - **Traffic Detection**: 20ร20ร7 grid (confidence, position, dimensions, orientation) |
| - **Waypoint Prediction**: 10 future trajectory points |
| - **Scene Understanding**: Junction, traffic light, and stop sign detection |
|
|
| ## ๐ Quick Start |
|
|
| ### Installation |
|
|
| ```bash |
| pip install torch torchvision timm huggingface_hub |
| ``` |
|
|
| ### Usage Example |
|
|
| ```python |
| import torch |
| from huggingface_hub import hf_hub_download |
| |
| # Download model weights |
| model_path = hf_hub_download( |
| repo_id="BaseerAI/Interfuser-Baseer-v1", |
| filename="best_model.pth" |
| ) |
| |
| # Load model (requires InterFuser class definition) |
| device = torch.device("cuda" if torch.cuda.is_available() else "cpu") |
| model = torch.load(model_path, map_location=device) |
| model.eval() |
| |
| # Inference |
| with torch.no_grad(): |
| outputs = model(input_data) |
| ``` |
|
|
| ## ๐ Performance |
|
|
| ### Training Details |
|
|
| - **Dataset**: PDM-Lite-CARLA (Urban driving scenarios) |
| - **Training Objective**: Multi-task learning with IoU optimization |
| - **Framework**: PyTorch |
|
|
| ### Key Metrics |
|
|
| - Optimized for traffic detection accuracy |
| - Enhanced bounding box IoU performance |
| - Robust waypoint prediction in urban scenarios |
|
|
| ## โ ๏ธ Limitations |
|
|
| ### Current Constraints |
|
|
| - **Simulation Only**: Trained exclusively on CARLA data |
| - **Single Camera**: Front-facing camera view only |
| - **No LiDAR**: Vision-based approach without LiDAR fusion |
| - **Dataset Scope**: Limited to PDM-Lite-CARLA scenarios |
|
|
| ### Recommended Use Cases |
|
|
| - โ
CARLA simulation environments |
| - โ
Research and development |
| - โ
Autonomous driving prototyping |
| - โ Real-world deployment (requires additional training) |
|
|
| ## ๐ ๏ธ Integration |
|
|
| This model is designed to work with: |
|
|
| - **[Baseer Self-Driving API](https://huggingface.co/spaces/BaseerAI/Baseer_Server)** - Live demo and API |
| - **CARLA Simulator** |
| - **PyTorch Inference Pipeline** |
| - **Custom Autonomous Driving Systems** |
|
|
| ## ๐ Citation |
|
|
| If you use this model in your research, please cite: |
|
|
| ```bibtex |
| @misc{interfuser-baseer-v1, |
| title={InterFuser-Baseer-v1: Fine-tuned Autonomous Driving Model}, |
| author={BaseerAI}, |
| year={2024}, |
| publisher={Hugging Face}, |
| howpublished={\url{https://huggingface.co/BaseerAI/Interfuser-Baseer-v1}} |
| } |
| ``` |
|
|
| ## ๐จโ๐ป Development |
|
|
| **Developed by**: Adam Altawil |
| **Project Type**: Graduation Project - AI & Autonomous Driving |
| **Institution**: [Your Institution Name] |
|
|
| ## ๐ License |
|
|
| This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. |
|
|
| ## ๐ค Contributing |
|
|
| Contributions, issues, and feature requests are welcome! Feel free to check the [issues page](../../issues). |
|
|
| ## ๐ Support |
|
|
| For questions and support: |
| - Try the live demo: **[Baseer Server Space](https://huggingface.co/spaces/BaseerAI/Baseer_Server)** |
| - Create an issue in this repository |
| - Contact: [Your Contact Information] |
|
|
| --- |
|
|
| <div align="center"> |
| <strong>๐ Drive the Future with AI ๐</strong> |
| </div> |