We introduce BigDocs-Bench a comprehensive benchmark suite designed to evaluate downstream tasks that transform visual inputs into structured outputs, such as GUI2UserIntent (fine-grained reasoning) and Image2Flow (structured output). We are actively working on releasing additional components of BigDocs-Bench and will update this repository as they become available.
For a part of BigDocs-Bench (GUI2UserIntent, GUI2Summary, GUI-VQA, and GUI2BBox), we do not explicitly distribute the images as part of this repository. You will find below instructions and a script facilitating the alignment of these images with our annotations. These instructions assumes a Linux-like environment.
wget.
wget -O seeclick_data.zip https://box.nju.edu.cn/f/6a804cf190dd490a808f/?dl=1
data_path defined by the user.
unzip seeclick_data.zip -d [data_path]
data_path as the one above where source images were downloaded.
import os
import datasets
from PIL import Image as PILImage
data_path = "" # your data path where unzipped images source can be found
def recover_image_column(dataset_dict, user_local_path, num_proc=os.cpu_count()-1):
def load_image(entry):
img_path = os.path.join(user_local_path, entry['img_id'])
try:
entry['image'] = PILImage.open(img_path)
except Exception as e:
raise RuntimeError(f"Error loading image at {img_path}: {e}")
entry.pop('img_id', None)
return entry
# Apply the mapping function to all splits in the DatasetDict
return dataset_dict.map(load_image, num_proc=num_proc)
repo_name = "ServiceNow/BigDocs-Bench"
# GUI2UserIntent
formal_name = "GUI2UserIntent"
GUI2UserIntent_raw = datasets.load_dataset(repo_name, formal_name)
GUI2UserIntent = recover_image_column(GUI2UserIntent_raw, data_path) # complete dataset
# GUI2Summary
formal_name = "GUI2Summary"
GUI2Summary_raw = datasets.load_dataset(repo_name, formal_name)
GUI2Summary = recover_image_column(GUI2Summary_raw, data_path) # complete dataset
# GUI-VQA
formal_name = "GUI-VQA"
GUI_VQA_raw = datasets.load_dataset(repo_name, formal_name)
GUI_VQA = recover_image_column(GUI_VQA_raw, data_path) # complete dataset
# GUI2BBox
formal_name = "GUI2BBox"
GUI2BBox_raw = datasets.load_dataset(repo_name, formal_name)
GUI2BBox = recover_image_column(GUI2BBox_raw, data_path) # complete dataset
# Other datasets don't need any particular processing.
Image2Flow_GraphViz = datasets.load_dataset(repo_name, "Image2Flow_(GraphViz)")
Image2Flow_JSON = datasets.load_dataset(repo_name, "Image2Flow_(JSON)")
Table2LaTex = datasets.load_dataset(repo_name, "Table2LaTex")
filter_out column in this dataset; please consider eschewing the samples for which this entry is True.The part of this repository generated by us is Copyright ServiceNow 2024 and licensed under the CC-BY-4.0 license.
Multiple datasets, documents, and tools were involved in the generation of BigDocs-Bench. We document these dependencies on a per-sample basis through the query_info, annotation_info and image_info fields, respectively documenting the query, annotations and image fields of our datasets. We summarize below these dependencies.
9 commits
We introduce BigDocs-Bench a comprehensive benchmark suite designed to evaluate downstream tasks that transform visual inputs into structured outputs, such as GUI2UserIntent (fine-grained reasoning) and Image2Flow (structured output). We are actively working on releasing additional components of BigDocs-Bench and will update this repository as they become available.
For a part of BigDocs-Bench (GUI2UserIntent, GUI2Summary, GUI-VQA, and GUI2BBox), we do not explicitly distribute the images as part of this repository. You will find below instructions and a script facilitating the alignment of these images with our annotations. These instructions assumes a Linux-like environment.
wget.
wget -O seeclick_data.zip https://box.nju.edu.cn/f/6a804cf190dd490a808f/?dl=1
data_path defined by the user.
unzip seeclick_data.zip -d [data_path]
data_path as the one above where source images were downloaded.
import os
import datasets
from PIL import Image as PILImage
data_path = "" # your data path where unzipped images source can be found
def recover_image_column(dataset_dict, user_local_path, num_proc=os.cpu_count()-1):
def load_image(entry):
img_path = os.path.join(user_local_path, entry['img_id'])
try:
entry['image'] = PILImage.open(img_path)
except Exception as e:
raise RuntimeError(f"Error loading image at {img_path}: {e}")
entry.pop('img_id', None)
return entry
# Apply the mapping function to all splits in the DatasetDict
return dataset_dict.map(load_image, num_proc=num_proc)
repo_name = "ServiceNow/BigDocs-Bench"
# GUI2UserIntent
formal_name = "GUI2UserIntent"
GUI2UserIntent_raw = datasets.load_dataset(repo_name, formal_name)
GUI2UserIntent = recover_image_column(GUI2UserIntent_raw, data_path) # complete dataset
# GUI2Summary
formal_name = "GUI2Summary"
GUI2Summary_raw = datasets.load_dataset(repo_name, formal_name)
GUI2Summary = recover_image_column(GUI2Summary_raw, data_path) # complete dataset
# GUI-VQA
formal_name = "GUI-VQA"
GUI_VQA_raw = datasets.load_dataset(repo_name, formal_name)
GUI_VQA = recover_image_column(GUI_VQA_raw, data_path) # complete dataset
# GUI2BBox
formal_name = "GUI2BBox"
GUI2BBox_raw = datasets.load_dataset(repo_name, formal_name)
GUI2BBox = recover_image_column(GUI2BBox_raw, data_path) # complete dataset
# Other datasets don't need any particular processing.
Image2Flow_GraphViz = datasets.load_dataset(repo_name, "Image2Flow_(GraphViz)")
Image2Flow_JSON = datasets.load_dataset(repo_name, "Image2Flow_(JSON)")
Table2LaTex = datasets.load_dataset(repo_name, "Table2LaTex")
filter_out column in this dataset; please consider eschewing the samples for which this entry is True.The part of this repository generated by us is Copyright ServiceNow 2024 and licensed under the CC-BY-4.0 license.
Multiple datasets, documents, and tools were involved in the generation of BigDocs-Bench. We document these dependencies on a per-sample basis through the query_info, annotation_info and image_info fields, respectively documenting the query, annotations and image fields of our datasets. We summarize below these dependencies.
9 commits