Video-Text-to-Text
Transformers
Safetensors
dispider_reaction
video
streaming-video
multimodal
qwen2
cvpr-2025
Instructions to use Mar2Ding/Dispider with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Mar2Ding/Dispider with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import Reaction model = Reaction.from_pretrained("Mar2Ding/Dispider", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Publish portable inference-only Dispider checkpoint
Browse files- README.md +113 -43
- config.json +9 -17
- dispider_checkpoint_manifest.json +39 -0
- {stream_compressor → perception_decision}/added_tokens.json +0 -0
- {stream_compressor → perception_decision}/config.json +9 -16
- {stream_compressor → perception_decision}/generation_config.json +0 -0
- {stream_compressor → perception_decision}/merges.txt +0 -0
- {stream_compressor → perception_decision}/special_tokens_map.json +0 -0
- {stream_compressor → perception_decision}/tokenizer_config.json +0 -0
- perception_decision/vision_tower/config.json +171 -0
- perception_decision/vision_tower/preprocessor_config.json +19 -0
- {stream_compressor → perception_decision}/vocab.json +0 -0
- stream_compressor/model.safetensors +0 -3
- trainer_state.json +0 -0
- training_args.bin +0 -3
README.md
CHANGED
|
@@ -1,50 +1,120 @@
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
|
|
|
| 3 |
pipeline_tag: video-text-to-text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4 |
---
|
| 5 |
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
|
| 10 |
-
<div align="center">
|
| 11 |
-
|
| 12 |
-
[💻Github Repo](https://github.com/Mark12Ding/Dispider)
|
| 13 |
-
|
| 14 |
-
[📖Paper](https://arxiv.org/abs/2501.03218)
|
| 15 |
-
|
| 16 |
-
</div>
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
## Quick Start
|
| 20 |
-
First download the checkpoints at the folder.
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
**Important**: Modify the ``mm_compressor`` path in config.json to align with your local environment. The checkpoint for ``mm_compressor`` is located within a sub-folder of this repository.
|
| 24 |
-
|
| 25 |
-
For detailed evaluation, please refer to [Github repo](https://github.com/Mark12Ding/Dispider).
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
| 32 |
-
## ✒️ Citation
|
| 33 |
-
If you find our work helpful for your research, please consider giving a star ⭐ and citation 📝.
|
| 34 |
```bibtex
|
| 35 |
-
@
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
author={Qian, Rui and Dong, Xiaoyi and Zhang, Pan and Zang, Yuhang and Ding, Shuangrui and Lin, Dahua and Wang, Jiaqi},
|
| 45 |
-
journal={Advances in Neural Information Processing Systems},
|
| 46 |
-
volume={37},
|
| 47 |
-
pages={119336--119360},
|
| 48 |
-
year={2025}
|
| 49 |
-
}
|
| 50 |
-
```
|
|
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
| 3 |
+
library_name: transformers
|
| 4 |
pipeline_tag: video-text-to-text
|
| 5 |
+
inference: false
|
| 6 |
+
tags:
|
| 7 |
+
- video
|
| 8 |
+
- streaming-video
|
| 9 |
+
- multimodal
|
| 10 |
+
- qwen2
|
| 11 |
+
- cvpr-2025
|
| 12 |
---
|
| 13 |
|
| 14 |
+
# Dispider
|
| 15 |
+
|
| 16 |
+
Official checkpoint for **Dispider: Enabling Video LLMs with Active Real-Time
|
| 17 |
+
Interaction via Disentangled Perception, Decision, and Reaction** (CVPR 2025).
|
| 18 |
+
|
| 19 |
+
- [Code](https://github.com/Mark12Ding/Dispider)
|
| 20 |
+
- [Paper](https://arxiv.org/abs/2501.03218)
|
| 21 |
+
|
| 22 |
+
Dispider continuously perceives a video stream, uses a compact Decision model
|
| 23 |
+
to determine when a response is needed, and invokes the larger Reaction model
|
| 24 |
+
only after a trigger.
|
| 25 |
+
|
| 26 |
+
## Architecture
|
| 27 |
+
|
| 28 |
+
| Component | Purpose | Backbone |
|
| 29 |
+
| --- | --- | --- |
|
| 30 |
+
| Perception | Encode each sampled 16-frame clip | CLIP vision tower |
|
| 31 |
+
| Perception-Decision | Build temporal memory | Compact Qwen2-1.5B |
|
| 32 |
+
| Decision | Trigger or remain silent | Decision head on the compact model |
|
| 33 |
+
| Reaction | Generate the response | Qwen2-7B |
|
| 34 |
+
|
| 35 |
+
## Checkpoint layout
|
| 36 |
+
|
| 37 |
+
The composite shards contain all model weights exactly once. The nested
|
| 38 |
+
`perception_decision/` directory contains metadata only.
|
| 39 |
+
|
| 40 |
+
```text
|
| 41 |
+
Dispider/
|
| 42 |
+
├── config.json
|
| 43 |
+
├── dispider_checkpoint_manifest.json
|
| 44 |
+
├── model-00001-of-00004.safetensors
|
| 45 |
+
├── model-00002-of-00004.safetensors
|
| 46 |
+
├── model-00003-of-00004.safetensors
|
| 47 |
+
├── model-00004-of-00004.safetensors
|
| 48 |
+
├── model.safetensors.index.json
|
| 49 |
+
└── perception_decision/
|
| 50 |
+
├── config.json
|
| 51 |
+
├── tokenizer metadata
|
| 52 |
+
└── vision_tower/
|
| 53 |
+
├── config.json
|
| 54 |
+
└── preprocessor_config.json
|
| 55 |
+
```
|
| 56 |
+
|
| 57 |
+
Download it directly:
|
| 58 |
+
|
| 59 |
+
```bash
|
| 60 |
+
huggingface-cli download Mar2Ding/Dispider \
|
| 61 |
+
--local-dir checkpoints/Dispider
|
| 62 |
+
```
|
| 63 |
+
|
| 64 |
+
Use the code repository with Python 3.10, PyTorch 2.2.0, FlashAttention
|
| 65 |
+
2.5.9.post1, and Transformers 4.41.2. Load either the repository ID or a local
|
| 66 |
+
snapshot through `dispider.model.load_pretrained_model`; generic
|
| 67 |
+
`AutoModel.from_pretrained()` does not assemble the video components.
|
| 68 |
+
The accompanying code is an inference-only runtime.
|
| 69 |
+
|
| 70 |
+
## Offline inference
|
| 71 |
+
|
| 72 |
+
```bash
|
| 73 |
+
CUDA_VISIBLE_DEVICES=0 python inference.py \
|
| 74 |
+
--model_path Mar2Ding/Dispider \
|
| 75 |
+
--video_path /path/to/video.mp4 \
|
| 76 |
+
--prompt "What is happening in the video?"
|
| 77 |
+
```
|
| 78 |
+
|
| 79 |
+
## Streaming inference
|
| 80 |
+
|
| 81 |
+
```bash
|
| 82 |
+
CUDA_VISIBLE_DEVICES=0 python stream_inference.py /path/to/video.mp4 \
|
| 83 |
+
--model Mar2Ding/Dispider \
|
| 84 |
+
--prompt "Tell me when the person starts performing." \
|
| 85 |
+
--decision-kv-cache auto
|
| 86 |
+
```
|
| 87 |
+
|
| 88 |
+
The command emits timestamped JSON responses as Decision triggers Reaction.
|
| 89 |
+
The optional Decision KV cache stores only stable prefixes and automatically
|
| 90 |
+
falls back to full computation near the trigger threshold.
|
| 91 |
+
|
| 92 |
+
## OVO-Bench example
|
| 93 |
+
|
| 94 |
+
From the code repository:
|
| 95 |
+
|
| 96 |
+
```bash
|
| 97 |
+
python scripts/evaluate_ovobench.py \
|
| 98 |
+
--ovo-root ../OVO-Bench \
|
| 99 |
+
--model-path checkpoints/Dispider \
|
| 100 |
+
--data-root /path/to/ovo-data \
|
| 101 |
+
--output-dir outputs/ovobench \
|
| 102 |
+
--gpus 0,1,2,3 \
|
| 103 |
+
--resume
|
| 104 |
+
```
|
| 105 |
+
|
| 106 |
+
The evaluator validates complete coverage, rejects missing or null outputs,
|
| 107 |
+
and computes the official category metrics. Generated results remain local.
|
| 108 |
+
|
| 109 |
+
## Citation
|
| 110 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 111 |
```bibtex
|
| 112 |
+
@inproceedings{qian2025dispider,
|
| 113 |
+
title={Dispider: Enabling Video {LLMs} with Active Real-Time Interaction via Disentangled Perception, Decision, and Reaction},
|
| 114 |
+
author={Qian, Rui and Ding, Shuangrui and Dong, Xiaoyi and Zhang, Pan and Zang, Yuhang and Cao, Yuhang and Lin, Dahua and Wang, Jiaqi},
|
| 115 |
+
booktitle={Proceedings of the Computer Vision and Pattern Recognition Conference (CVPR)},
|
| 116 |
+
pages={24045--24055},
|
| 117 |
+
month={June},
|
| 118 |
+
year={2025}
|
| 119 |
+
}
|
| 120 |
+
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
config.json
CHANGED
|
@@ -1,31 +1,26 @@
|
|
| 1 |
{
|
| 2 |
-
"_name_or_path": "
|
| 3 |
"architectures": [
|
| 4 |
-
"
|
| 5 |
],
|
| 6 |
"attention_dropout": 0.0,
|
| 7 |
"bos_token_id": 151643,
|
| 8 |
-
"
|
| 9 |
-
"
|
| 10 |
-
"
|
| 11 |
-
"compress_projector_lr": null,
|
| 12 |
-
"compress_projector_type": "mlp2x_gelu",
|
| 13 |
"eos_token_id": 151645,
|
| 14 |
-
"freeze_compress_mlp_adapter": false,
|
| 15 |
"hidden_act": "silu",
|
| 16 |
"hidden_size": 3584,
|
| 17 |
-
"image_aspect_ratio": "square",
|
| 18 |
"initializer_range": 0.02,
|
| 19 |
"intermediate_size": 18944,
|
| 20 |
"max_position_embeddings": 32768,
|
| 21 |
-
"
|
| 22 |
-
"mm_compressor": "/mnt/petrelfs/dingshuangrui/LLaVA/checkpoints/long-qwen-16f-64r-4p-16-causal-qwen-streaming-final/stream_compressor",
|
| 23 |
-
"mm_use_im_patch_token": false,
|
| 24 |
-
"mm_use_im_start_end": false,
|
| 25 |
-
"model_type": "qwen2",
|
| 26 |
"num_attention_heads": 28,
|
| 27 |
"num_hidden_layers": 28,
|
| 28 |
"num_key_value_heads": 4,
|
|
|
|
|
|
|
|
|
|
| 29 |
"rms_norm_eps": 1e-06,
|
| 30 |
"rope_theta": 1000000.0,
|
| 31 |
"sliding_window": 131072,
|
|
@@ -34,10 +29,7 @@
|
|
| 34 |
"tokenizer_padding_side": "right",
|
| 35 |
"torch_dtype": "bfloat16",
|
| 36 |
"transformers_version": "4.41.2",
|
| 37 |
-
"tune_clip_mlp_adapter": false,
|
| 38 |
-
"tune_compress_mlp_adapter": false,
|
| 39 |
"use_cache": true,
|
| 40 |
-
"use_compress_proj": true,
|
| 41 |
"use_sliding_window": false,
|
| 42 |
"vocab_size": 152064
|
| 43 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"_name_or_path": ".",
|
| 3 |
"architectures": [
|
| 4 |
+
"Reaction"
|
| 5 |
],
|
| 6 |
"attention_dropout": 0.0,
|
| 7 |
"bos_token_id": 151643,
|
| 8 |
+
"checkpoint_format_version": 2,
|
| 9 |
+
"decision_hidden_size": 1536,
|
| 10 |
+
"decision_projector_type": "mlp2x_gelu",
|
|
|
|
|
|
|
| 11 |
"eos_token_id": 151645,
|
|
|
|
| 12 |
"hidden_act": "silu",
|
| 13 |
"hidden_size": 3584,
|
|
|
|
| 14 |
"initializer_range": 0.02,
|
| 15 |
"intermediate_size": 18944,
|
| 16 |
"max_position_embeddings": 32768,
|
| 17 |
+
"model_type": "dispider_reaction",
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
"num_attention_heads": 28,
|
| 19 |
"num_hidden_layers": 28,
|
| 20 |
"num_key_value_heads": 4,
|
| 21 |
+
"perception_decision": "perception_decision",
|
| 22 |
+
"perception_hidden_size": 4096,
|
| 23 |
+
"perception_projector_type": "mlp2x_gelu",
|
| 24 |
"rms_norm_eps": 1e-06,
|
| 25 |
"rope_theta": 1000000.0,
|
| 26 |
"sliding_window": 131072,
|
|
|
|
| 29 |
"tokenizer_padding_side": "right",
|
| 30 |
"torch_dtype": "bfloat16",
|
| 31 |
"transformers_version": "4.41.2",
|
|
|
|
|
|
|
| 32 |
"use_cache": true,
|
|
|
|
| 33 |
"use_sliding_window": false,
|
| 34 |
"vocab_size": 152064
|
| 35 |
}
|
dispider_checkpoint_manifest.json
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"embedded_perception_decision": {
|
| 3 |
+
"composite_files": [
|
| 4 |
+
"model-00001-of-00004.safetensors",
|
| 5 |
+
"model-00002-of-00004.safetensors",
|
| 6 |
+
"model-00003-of-00004.safetensors",
|
| 7 |
+
"model-00004-of-00004.safetensors"
|
| 8 |
+
],
|
| 9 |
+
"state_dict_prefix": "model.compressor.compressor.",
|
| 10 |
+
"verification": "dtype+shape+torch.equal",
|
| 11 |
+
"verified_key_count": 735
|
| 12 |
+
},
|
| 13 |
+
"files": [
|
| 14 |
+
".gitattributes",
|
| 15 |
+
"README.md",
|
| 16 |
+
"added_tokens.json",
|
| 17 |
+
"config.json",
|
| 18 |
+
"generation_config.json",
|
| 19 |
+
"merges.txt",
|
| 20 |
+
"model-00001-of-00004.safetensors",
|
| 21 |
+
"model-00002-of-00004.safetensors",
|
| 22 |
+
"model-00003-of-00004.safetensors",
|
| 23 |
+
"model-00004-of-00004.safetensors",
|
| 24 |
+
"model.safetensors.index.json",
|
| 25 |
+
"perception_decision/added_tokens.json",
|
| 26 |
+
"perception_decision/config.json",
|
| 27 |
+
"perception_decision/generation_config.json",
|
| 28 |
+
"perception_decision/merges.txt",
|
| 29 |
+
"perception_decision/special_tokens_map.json",
|
| 30 |
+
"perception_decision/tokenizer_config.json",
|
| 31 |
+
"perception_decision/vision_tower/config.json",
|
| 32 |
+
"perception_decision/vision_tower/preprocessor_config.json",
|
| 33 |
+
"perception_decision/vocab.json",
|
| 34 |
+
"special_tokens_map.json",
|
| 35 |
+
"tokenizer_config.json",
|
| 36 |
+
"vocab.json"
|
| 37 |
+
],
|
| 38 |
+
"format_version": 2
|
| 39 |
+
}
|
{stream_compressor → perception_decision}/added_tokens.json
RENAMED
|
File without changes
|
{stream_compressor → perception_decision}/config.json
RENAMED
|
@@ -1,31 +1,26 @@
|
|
| 1 |
{
|
| 2 |
-
"_name_or_path": "
|
| 3 |
"architectures": [
|
| 4 |
-
"
|
| 5 |
],
|
| 6 |
"attention_dropout": 0.0,
|
| 7 |
"bos_token_id": 151643,
|
|
|
|
| 8 |
"eos_token_id": 151645,
|
| 9 |
-
"freeze_mm_mlp_adapter": false,
|
| 10 |
"hidden_act": "silu",
|
| 11 |
"hidden_size": 1536,
|
| 12 |
-
"image_aspect_ratio": "square",
|
| 13 |
"initializer_range": 0.02,
|
| 14 |
"intermediate_size": 8960,
|
| 15 |
"max_position_embeddings": 32768,
|
| 16 |
-
"
|
| 17 |
-
"mm_hidden_size": 1024,
|
| 18 |
-
"mm_projector_lr": null,
|
| 19 |
-
"mm_projector_type": "pool",
|
| 20 |
-
"mm_use_im_patch_token": false,
|
| 21 |
-
"mm_use_im_start_end": false,
|
| 22 |
-
"mm_vision_select_feature": "patch",
|
| 23 |
-
"mm_vision_select_layer": -2,
|
| 24 |
-
"mm_vision_tower": "openai/clip-vit-large-patch14",
|
| 25 |
-
"model_type": "stream_ground_qwen",
|
| 26 |
"num_attention_heads": 12,
|
| 27 |
"num_hidden_layers": 28,
|
| 28 |
"num_key_value_heads": 2,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 29 |
"pool_num": 4,
|
| 30 |
"resolution": 64,
|
| 31 |
"rms_norm_eps": 1e-06,
|
|
@@ -36,9 +31,7 @@
|
|
| 36 |
"tokenizer_padding_side": "right",
|
| 37 |
"torch_dtype": "bfloat16",
|
| 38 |
"transformers_version": "4.41.2",
|
| 39 |
-
"tune_mm_mlp_adapter": false,
|
| 40 |
"use_cache": true,
|
| 41 |
-
"use_mm_proj": true,
|
| 42 |
"use_sliding_window": false,
|
| 43 |
"vocab_size": 151936
|
| 44 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"_name_or_path": "perception_decision",
|
| 3 |
"architectures": [
|
| 4 |
+
"Decision"
|
| 5 |
],
|
| 6 |
"attention_dropout": 0.0,
|
| 7 |
"bos_token_id": 151643,
|
| 8 |
+
"checkpoint_format_version": 2,
|
| 9 |
"eos_token_id": 151645,
|
|
|
|
| 10 |
"hidden_act": "silu",
|
| 11 |
"hidden_size": 1536,
|
|
|
|
| 12 |
"initializer_range": 0.02,
|
| 13 |
"intermediate_size": 8960,
|
| 14 |
"max_position_embeddings": 32768,
|
| 15 |
+
"model_type": "dispider_decision",
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
"num_attention_heads": 12,
|
| 17 |
"num_hidden_layers": 28,
|
| 18 |
"num_key_value_heads": 2,
|
| 19 |
+
"perception_vision_tower": "vision_tower",
|
| 20 |
+
"perception_hidden_size": 1024,
|
| 21 |
+
"perception_projector_type": "pool",
|
| 22 |
+
"perception_select_feature": "patch",
|
| 23 |
+
"perception_select_layer": -2,
|
| 24 |
"pool_num": 4,
|
| 25 |
"resolution": 64,
|
| 26 |
"rms_norm_eps": 1e-06,
|
|
|
|
| 31 |
"tokenizer_padding_side": "right",
|
| 32 |
"torch_dtype": "bfloat16",
|
| 33 |
"transformers_version": "4.41.2",
|
|
|
|
| 34 |
"use_cache": true,
|
|
|
|
| 35 |
"use_sliding_window": false,
|
| 36 |
"vocab_size": 151936
|
| 37 |
}
|
{stream_compressor → perception_decision}/generation_config.json
RENAMED
|
File without changes
|
{stream_compressor → perception_decision}/merges.txt
RENAMED
|
File without changes
|
{stream_compressor → perception_decision}/special_tokens_map.json
RENAMED
|
File without changes
|
{stream_compressor → perception_decision}/tokenizer_config.json
RENAMED
|
File without changes
|
perception_decision/vision_tower/config.json
ADDED
|
@@ -0,0 +1,171 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"_name_or_path": "clip-vit-large-patch14/",
|
| 3 |
+
"architectures": [
|
| 4 |
+
"CLIPModel"
|
| 5 |
+
],
|
| 6 |
+
"initializer_factor": 1.0,
|
| 7 |
+
"logit_scale_init_value": 2.6592,
|
| 8 |
+
"model_type": "clip",
|
| 9 |
+
"projection_dim": 768,
|
| 10 |
+
"text_config": {
|
| 11 |
+
"_name_or_path": "",
|
| 12 |
+
"add_cross_attention": false,
|
| 13 |
+
"architectures": null,
|
| 14 |
+
"attention_dropout": 0.0,
|
| 15 |
+
"bad_words_ids": null,
|
| 16 |
+
"bos_token_id": 0,
|
| 17 |
+
"chunk_size_feed_forward": 0,
|
| 18 |
+
"cross_attention_hidden_size": null,
|
| 19 |
+
"decoder_start_token_id": null,
|
| 20 |
+
"diversity_penalty": 0.0,
|
| 21 |
+
"do_sample": false,
|
| 22 |
+
"dropout": 0.0,
|
| 23 |
+
"early_stopping": false,
|
| 24 |
+
"encoder_no_repeat_ngram_size": 0,
|
| 25 |
+
"eos_token_id": 2,
|
| 26 |
+
"finetuning_task": null,
|
| 27 |
+
"forced_bos_token_id": null,
|
| 28 |
+
"forced_eos_token_id": null,
|
| 29 |
+
"hidden_act": "quick_gelu",
|
| 30 |
+
"hidden_size": 768,
|
| 31 |
+
"id2label": {
|
| 32 |
+
"0": "LABEL_0",
|
| 33 |
+
"1": "LABEL_1"
|
| 34 |
+
},
|
| 35 |
+
"initializer_factor": 1.0,
|
| 36 |
+
"initializer_range": 0.02,
|
| 37 |
+
"intermediate_size": 3072,
|
| 38 |
+
"is_decoder": false,
|
| 39 |
+
"is_encoder_decoder": false,
|
| 40 |
+
"label2id": {
|
| 41 |
+
"LABEL_0": 0,
|
| 42 |
+
"LABEL_1": 1
|
| 43 |
+
},
|
| 44 |
+
"layer_norm_eps": 1e-05,
|
| 45 |
+
"length_penalty": 1.0,
|
| 46 |
+
"max_length": 20,
|
| 47 |
+
"max_position_embeddings": 77,
|
| 48 |
+
"min_length": 0,
|
| 49 |
+
"model_type": "clip_text_model",
|
| 50 |
+
"no_repeat_ngram_size": 0,
|
| 51 |
+
"num_attention_heads": 12,
|
| 52 |
+
"num_beam_groups": 1,
|
| 53 |
+
"num_beams": 1,
|
| 54 |
+
"num_hidden_layers": 12,
|
| 55 |
+
"num_return_sequences": 1,
|
| 56 |
+
"output_attentions": false,
|
| 57 |
+
"output_hidden_states": false,
|
| 58 |
+
"output_scores": false,
|
| 59 |
+
"pad_token_id": 1,
|
| 60 |
+
"prefix": null,
|
| 61 |
+
"problem_type": null,
|
| 62 |
+
"projection_dim" : 768,
|
| 63 |
+
"pruned_heads": {},
|
| 64 |
+
"remove_invalid_values": false,
|
| 65 |
+
"repetition_penalty": 1.0,
|
| 66 |
+
"return_dict": true,
|
| 67 |
+
"return_dict_in_generate": false,
|
| 68 |
+
"sep_token_id": null,
|
| 69 |
+
"task_specific_params": null,
|
| 70 |
+
"temperature": 1.0,
|
| 71 |
+
"tie_encoder_decoder": false,
|
| 72 |
+
"tie_word_embeddings": true,
|
| 73 |
+
"tokenizer_class": null,
|
| 74 |
+
"top_k": 50,
|
| 75 |
+
"top_p": 1.0,
|
| 76 |
+
"torch_dtype": null,
|
| 77 |
+
"torchscript": false,
|
| 78 |
+
"transformers_version": "4.16.0.dev0",
|
| 79 |
+
"use_bfloat16": false,
|
| 80 |
+
"vocab_size": 49408
|
| 81 |
+
},
|
| 82 |
+
"text_config_dict": {
|
| 83 |
+
"hidden_size": 768,
|
| 84 |
+
"intermediate_size": 3072,
|
| 85 |
+
"num_attention_heads": 12,
|
| 86 |
+
"num_hidden_layers": 12,
|
| 87 |
+
"projection_dim": 768
|
| 88 |
+
},
|
| 89 |
+
"torch_dtype": "float32",
|
| 90 |
+
"transformers_version": null,
|
| 91 |
+
"vision_config": {
|
| 92 |
+
"_name_or_path": "",
|
| 93 |
+
"add_cross_attention": false,
|
| 94 |
+
"architectures": null,
|
| 95 |
+
"attention_dropout": 0.0,
|
| 96 |
+
"bad_words_ids": null,
|
| 97 |
+
"bos_token_id": null,
|
| 98 |
+
"chunk_size_feed_forward": 0,
|
| 99 |
+
"cross_attention_hidden_size": null,
|
| 100 |
+
"decoder_start_token_id": null,
|
| 101 |
+
"diversity_penalty": 0.0,
|
| 102 |
+
"do_sample": false,
|
| 103 |
+
"dropout": 0.0,
|
| 104 |
+
"early_stopping": false,
|
| 105 |
+
"encoder_no_repeat_ngram_size": 0,
|
| 106 |
+
"eos_token_id": null,
|
| 107 |
+
"finetuning_task": null,
|
| 108 |
+
"forced_bos_token_id": null,
|
| 109 |
+
"forced_eos_token_id": null,
|
| 110 |
+
"hidden_act": "quick_gelu",
|
| 111 |
+
"hidden_size": 1024,
|
| 112 |
+
"id2label": {
|
| 113 |
+
"0": "LABEL_0",
|
| 114 |
+
"1": "LABEL_1"
|
| 115 |
+
},
|
| 116 |
+
"image_size": 224,
|
| 117 |
+
"initializer_factor": 1.0,
|
| 118 |
+
"initializer_range": 0.02,
|
| 119 |
+
"intermediate_size": 4096,
|
| 120 |
+
"is_decoder": false,
|
| 121 |
+
"is_encoder_decoder": false,
|
| 122 |
+
"label2id": {
|
| 123 |
+
"LABEL_0": 0,
|
| 124 |
+
"LABEL_1": 1
|
| 125 |
+
},
|
| 126 |
+
"layer_norm_eps": 1e-05,
|
| 127 |
+
"length_penalty": 1.0,
|
| 128 |
+
"max_length": 20,
|
| 129 |
+
"min_length": 0,
|
| 130 |
+
"model_type": "clip_vision_model",
|
| 131 |
+
"no_repeat_ngram_size": 0,
|
| 132 |
+
"num_attention_heads": 16,
|
| 133 |
+
"num_beam_groups": 1,
|
| 134 |
+
"num_beams": 1,
|
| 135 |
+
"num_hidden_layers": 24,
|
| 136 |
+
"num_return_sequences": 1,
|
| 137 |
+
"output_attentions": false,
|
| 138 |
+
"output_hidden_states": false,
|
| 139 |
+
"output_scores": false,
|
| 140 |
+
"pad_token_id": null,
|
| 141 |
+
"patch_size": 14,
|
| 142 |
+
"prefix": null,
|
| 143 |
+
"problem_type": null,
|
| 144 |
+
"projection_dim" : 768,
|
| 145 |
+
"pruned_heads": {},
|
| 146 |
+
"remove_invalid_values": false,
|
| 147 |
+
"repetition_penalty": 1.0,
|
| 148 |
+
"return_dict": true,
|
| 149 |
+
"return_dict_in_generate": false,
|
| 150 |
+
"sep_token_id": null,
|
| 151 |
+
"task_specific_params": null,
|
| 152 |
+
"temperature": 1.0,
|
| 153 |
+
"tie_encoder_decoder": false,
|
| 154 |
+
"tie_word_embeddings": true,
|
| 155 |
+
"tokenizer_class": null,
|
| 156 |
+
"top_k": 50,
|
| 157 |
+
"top_p": 1.0,
|
| 158 |
+
"torch_dtype": null,
|
| 159 |
+
"torchscript": false,
|
| 160 |
+
"transformers_version": "4.16.0.dev0",
|
| 161 |
+
"use_bfloat16": false
|
| 162 |
+
},
|
| 163 |
+
"vision_config_dict": {
|
| 164 |
+
"hidden_size": 1024,
|
| 165 |
+
"intermediate_size": 4096,
|
| 166 |
+
"num_attention_heads": 16,
|
| 167 |
+
"num_hidden_layers": 24,
|
| 168 |
+
"patch_size": 14,
|
| 169 |
+
"projection_dim": 768
|
| 170 |
+
}
|
| 171 |
+
}
|
perception_decision/vision_tower/preprocessor_config.json
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"crop_size": 224,
|
| 3 |
+
"do_center_crop": true,
|
| 4 |
+
"do_normalize": true,
|
| 5 |
+
"do_resize": true,
|
| 6 |
+
"feature_extractor_type": "CLIPFeatureExtractor",
|
| 7 |
+
"image_mean": [
|
| 8 |
+
0.48145466,
|
| 9 |
+
0.4578275,
|
| 10 |
+
0.40821073
|
| 11 |
+
],
|
| 12 |
+
"image_std": [
|
| 13 |
+
0.26862954,
|
| 14 |
+
0.26130258,
|
| 15 |
+
0.27577711
|
| 16 |
+
],
|
| 17 |
+
"resample": 3,
|
| 18 |
+
"size": 224
|
| 19 |
+
}
|
{stream_compressor → perception_decision}/vocab.json
RENAMED
|
File without changes
|
stream_compressor/model.safetensors
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:dae10330fbf1f2b7201903d840701ce035de69530645bcbc1e9cac3f9abbd9e6
|
| 3 |
-
size 4177946928
|
|
|
|
|
|
|
|
|
|
|
|
trainer_state.json
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
training_args.bin
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:e471f601782d00eb4fecfbdb7b2253a1151dd38b3cd18b70108b018465207fb0
|
| 3 |
-
size 6776
|
|
|
|
|
|
|
|
|
|
|
|