Scene Graph-guided SegCaptioning Transformer with Fine-grained Alignment for Controllable Video Segmentation and Captioning
Authors: Xu Zhang, Jin Yuan, BinHong Yang, Xuan Liu, Qianjun Zhang, Yuyi Wang, Zhiyong Li, Hanwang Zhang
Organizations: the College of Computer Science and Electronic Engineering, Hunan University, Changsha 410082, China. · the School of Computing and Artificial Intelligence, Southwest Jiaotong University, Chengdu 611756, P.R. China. · CRRC Zhuzhou Institute Company Ltd., Zhuzhou, Hunan 412001, China. · the School of Robotics and the National Engineering Research Center of Robot Visual Perception and Control Technology, Hunan University, Changsha 410082, China. · Nanyang Technological University, Singapore 639798.
Recent advancements in multimodal large models have significantly bridged the representation gap between diverse modalities, catalyzing the evolution of video multimodal interpretation, which enhances users' understanding of video content by generating correlated modalities. However, most existing video multimodal interpretation methods primarily concentrate on global comprehension with limited user interaction. To address this, we propose a novel task, Controllable Video Segmentation and Captioning (SegCaptioning), which empowers users to provide specific prompts, such as a bounding box around an object of interest, to simultaneously generate correlated masks and captions that precisely embody user intent. An innovative framework Scene Graph-guided Fine-grained SegCaptioning Transformer (SG-FSCFormer) is designed that integrates a Prompt-guided Temporal Graph Former to effectively captures and represents user intent through an adaptive prompt adaptor, ensuring that the generated content well aligns with the user's requirements. Furthermore, our model introduces a Fine-grained Mask-linguistic Decoder to collaboratively predict high-quality caption-mask pairs using a Multi-entity Contrastive loss, as well as provide fine-grained alignment between each mask and its corresponding caption tokens, thereby enhancing users' comprehension of videos. Comprehensive experiments conducted on two benchmark datasets demonstrate that SG-FSCFormer achieves remarkable performance, effectively capturing user intent and generating precise multimodal outputs tailored to user specifications. Our code is available at https://github.com/XuZhang1211/SG-FSCFormer.
Figures & tables
Fig. 1 : An example to illustrate the difference between the segmentation and captioning method and our approach, which allows users to provide a bounding box to generate multimodal outputs that are tailored to the user’s intent.
Fig. 2 : Framework of our Scene Graph-guided Fine-grained SegCaptioning Transformer (SG-FSCFormer), consisting of three components: a Visual Encoder, a Prompt-guided Temporal Graph Former (PTGFormer), and a Fine-grained Mask-Linguistic Decoder (MLDecoder), where the mathematical symbols are explained in the corresponding modules.
Fig. 3 : Prediction by the revised decoder which is able to output the position of caption words for each mask instance.
Fig. 4 : An example illustrating our data annotation.
Fig. 5 : Quantitative results by different approaches tested on the LV-VIS and OVIS datasets, where the color indicates the matching relationship between masks and words.
Model
LLM
LV-VIS
OVIS
YouCook2
METEOR
SPICE
CIDEr
METEOR
SPICE
CIDEr
METEOR
SPICE
CIDEr
Vid2Seq CVPR23 [ 60 ]
T5-Base
16.3
24.7
107.4
18.0
33.0
106.8
9.3
7.9
47.1
SMOTer ECCV24 [ 51 ]
GRiT
16.9
25.0
109.6
17.8
32.8
108.1
-
-
-
MA-LMM CVPR24 [ 1 ]
Vicuna-7B
17.1
25.2
110.6
18.6
33.1
109.3
17.6
31.5
131.2
VideoGLaMM CVPR25 [ 52 ]
Phi3-Mini-3.8B
16.7
25.7
112.0
19.5
33.9
112.8
15.4
28.7
124.3
SG-FSCFormer (ours)
Vicuna-7B
19.3
26.8
112.5
21.4
35.2
113.7
20.5
33.4
139.6
TABLE I : Performance comparison with the advanced video captioning methods. where the results on the LV-VIS and OVIS are reproduced and that on the YouCook2 is cited from the references.
Model
LV-VIS
OVIS
J&F
J
F
J&F
J
F
SAMURAI arXiv24 [ 61 ]
87.3
85.6
89.1
72.0
69.2
74.9
SAM2 ICLR25 [ 45 ]
85.6
83.3
87.9
68.7
66.0
71.3
SG-FSCFormer (ours)
87.8
85.9
89.7
74.6
72.5
76.7
TABLE II : Performance comparison between our approach and the two controllable video segmentation methods.
Model
Mask Decoder
LV-VIS
OVIS
AP
AP 50
AP 75
AP
AP 50
AP 75
GLEE CVPR24 [ 63 ]
MaskDINO
23.9
24.6
23.3
27.1
45.4
26.3
OVFormer ECCV24 [ 36 ]
Mask2Former
24.7
31.1
26.5
21.3
38.5
20.8
OW-VISCap NIPS24 [ 21 ]
Mask2Former
-
-
-
25.4
48.8
22.8
SG-FSCFormer (ours)
Mask2Former
25.2
31.8
27.5
27.8
49.0
27.2
VideoGLaMM CVPR25 [ 52 ]
SAM2
25.4
32.2
27.6
28.0
49.3
26.9
TABLE III : Performance comparison with several advanced video multimodal interpretation methods, where † denotes the evaluation using the instance-level AP.
Spa.
Tem.
SPICE
CIDEr
J&F
AP
-
-
24.6
108.3
85.0
23.9
✓
-
25.7
111.2
86.5
25.4
-
✓
25.3
109.8
86.4
25.1
✓
✓
26.8
112.5
87.8
26.0
TABLE IV : Performance comparison of PTGFormer using the adaptor with different components tested on the LV-VIS validation set, where “spa.” and “tem.” represent the use of spatial and temporal correlations, respectively.
LFA
LMC
SPICE
CIDEr
J&F
AP
-
-
23.8
106.9
84.5
22.1
✓
-
25.4
109.8
86.3
25.6
-
✓
25.1
110.4
86.9
25.8
✓
✓
26.8
112.5
87.8
26.0
TABLE V : Performance comparison by using different components of losses tested on the LV-VIS Val dataset.
λ
0
1
2
5
10
SPICE
23.8
25.4
26.8
26.3
25.7
CIDEr
106.9
110.6
112.5
112.0
111.3
J&F
84.5
85.7
87.8
86.5
86.1
AP
22.1
25.3
26.0
25.9
25.4
TABLE VI : Performance comparison by using LMC with different weights tested on the LV-VIS Val dataset.
Fig. 6 : Visualization of several challenging and failure cases, including heavy occlusion, motion blur, visual ambiguity, and long-term target disappearance.
Method
SPICE
CIDEr
J&F
AP
Our (Vicuna-7B&SAM2)
26.8
112.5
87.8
26.0
Without Prompt Box
Our (w/o Prompt)
25.4
110.8
86.5
25.3
Using Different LLMs
Our (OPT-2.7B)
25.9
111.2
87.4
25.7
Using Different Mask Decoders
TABLE VII : Performance comparison of three SG-FSCFormer variants, analyzing the impact of removing the prompt box, replacing the LLM, and using different mask decoders.
Module
PTGFormer
MLDecoder
Params
10.2M
85.7M
FLOPs
1.8G
3.1G
TABLE VIII : Parameters and FLOPs of the trainable modules in SG-FSCFormer.