mllmTeam commited on
Commit
7e334b7
1 Parent(s): 1e918d4
Files changed (1) hide show
  1. README.md +115 -91
README.md CHANGED
@@ -1,3 +1,4 @@
 
1
  ---
2
  language: [en]
3
  license: mit
@@ -19,37 +20,60 @@ task_ids:
19
  # MobileViews: A Large-Scale Mobile GUI Dataset
20
  [**Read the paper**](https://arxiv.org/abs/2409.14337)
21
 
22
- **MobileViews** is a large-scale dataset designed to support research in mobile user interface (UI) analysis and mobile agents. Our first version — **MobileViews-600K** — contains over **600,000** mobile UI screenshot-view hierarchy (VH) pairs, collected from approximately **20,000 apps** on the Google Play Store.
23
-
24
 
25
  ## Dataset Overview
26
 
27
- The dataset includes several `.zip` files, each containing screenshot-VH pairs and corresponding CSV index files, which map each screenshot to its respective view hierarchy (VH).
28
 
 
29
 
30
- - `MobileViews_0-150000.zip` (23 GB) and `MobileViews_index_0-150000.csv`: The first set of screenshot-VH pairs, containing IDs from 0 to 150000.
31
- - `MobileViews_150001-291197.zip` (36 GB) and `MobileViews_index_150001-291197.csv`: The second set of screenshot-VH pairs, containing IDs from 150001 to 291197.
32
- - `MobileViews_300000-522301.zip` (37 GB) and `MobileViews_index_300000-522301.csv`: The third set of screenshot-VH pairs, containing IDs from 300000 to 522301.
33
- - `AppMetadata.csv`: App metadata for **15,000 apps** from the Google Play Store, retrieved in **June 2024**.
34
 
35
- ### Index CSV Columns
36
 
37
- Each index CSV file contains the following columns, mapping each screenshot to its corresponding view hierarchy:
38
 
39
- | Column | Description |
40
- |--------------|-------------------------------------------|
41
- | `Image File` | Filename of the screenshot (e.g., 0.jpg) |
42
- | `JSON File` | Filename of the view hierarchy (e.g., 0.json) |
43
 
44
- **Example:**
45
- ```csv
46
- Image File,JSON File
47
- 300000.jpg,300000.json
48
- 300001.jpg,300001.json
49
- 300002.jpg,300002.json
50
- ```
51
 
52
- Each `.zip` file contains both the screenshots (JPG) and view hierarchy files (JSON).
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
53
 
54
  ### AppMetadata.csv Columns
55
 
@@ -66,7 +90,7 @@ The `AppMetadata.csv` file contains detailed information about each app. The col
66
  | `reviews` | Number of reviews |
67
  | `histogram` | Rating distribution |
68
  | `price` | App price |
69
- | `free` | Indicates if the app is free (True/False) |
70
  | `offersIAP` | Offers in-app purchases (True/False) |
71
  | `inAppProductPrice` | In-app product price |
72
  | `developer` | Developer name |
@@ -81,101 +105,101 @@ The `AppMetadata.csv` file contains detailed information about each app. The col
81
  | `lastUpdatedOn` | Date of the latest update |
82
  | `appId` | Unique app identifier |
83
 
 
 
 
 
 
 
 
 
 
84
 
85
- ## How to Download
86
 
87
- You can download the dataset using the following methods:
 
88
 
89
- 1. **Download via Web UI**:
90
-
91
- Hugging Face provides a direct download button for each file on the dataset page. Simply click the download button next to the desired `.zip` or `.csv` file.
92
-
 
93
 
94
- 2. **Download via `wget`**:
95
 
96
- You can also use `wget` to download the files, which allows you to resume the download if interrupted:
 
97
 
98
- ```bash
99
- wget -c https://huggingface.co/datasets/mllmTeam/MobileViews/resolve/main/MobileViews_0-150000.zip
100
- wget -c https://huggingface.co/datasets/mllmTeam/MobileViews/resolve/main/MobileViews_150001-291197.zip
101
- wget -c https://huggingface.co/datasets/mllmTeam/MobileViews/resolve/main/MobileViews_300000-522301.zip
102
- ```
103
 
104
- 3. **Download via Git LFS**:
105
 
106
- Alternatively, you can clone the repository and pull the large files via Git LFS:
107
 
108
- ```bash
109
- git clone https://huggingface.co/datasets/mllmTeam/MobileViews
110
- cd MobileViews
111
- git lfs pull
112
- ```
113
 
114
- ## File Verification
 
 
115
 
116
- To ensure the downloaded files are complete and correct, you can verify them in multiple ways.
 
 
117
 
118
- 1. **Verify Integrity Using `zip -T`**:
119
-
120
- ```bash
121
- zip -T MobileViews_0-150000.zip # expected output: test of MobileViews_0-150000.zip OK
122
- zip -T MobileViews_150001-291197.zip # expected output: test of MobileViews_150001-291197.zip OK
123
- zip -T MobileViews_300000-522301.zip # expected output: test of MobileViews_300000-522301.zip OK
124
- ```
125
 
126
- 2. **Verify the Number of Files**:
127
-
128
- You can verify the number of `.jpg` and `.json` files inside the `.zip`:
129
-
130
- ```bash
131
- # Check the number of JSON files
132
- unzip -l MobileViews_0-150000.zip | grep ".json" | wc -l # expected output: 150001
133
- unzip -l MobileViews_150001-291197.zip | grep ".json" | wc -l # expected output: 141197
134
- unzip -l MobileViews_300000-522301.zip | grep ".json" | wc -l # expected output: 222302
135
-
136
- # Check the number of JPG files
137
- unzip -l MobileViews_0-150000.zip | grep ".jpg" | wc -l # expected output: 150001
138
- unzip -l MobileViews_150001-291197.zip | grep ".jpg" | wc -l # expected output: 141197
139
- unzip -l MobileViews_300000-522301.zip | grep ".jpg" | wc -l # expected output: 222302
140
- ```
141
 
142
- 3. **Verify the File Size**:
 
 
143
 
144
- You can verify that the file sizes match the expected sizes:
145
 
146
- ```bash
147
- du -sh MobileViews_0-150000.zip # expected output: 23G
148
- du -sh MobileViews_150001-291197.zip # expected output: 36G
149
- du -sh MobileViews_300000-522301.zip # expected output: 37G
150
- ```
 
151
 
152
- 4. **Verify Using SHA256**:
 
 
 
 
 
153
 
154
- We provide SHA256 checksum files to verify the integrity of the downloaded .zip files:
 
 
 
 
 
155
 
156
- ```bash
157
- sha256sum -c MobileViews_0-150000.zip.sha256 # expected output: MobileViews_0-150000.zip: OK
158
- sha256sum -c MobileViews_150001-291197.zip.sha256 # expected output: MobileViews_150001-291197.zip: OK
159
- sha256sum -c MobileViews_300000-522301.zip.sha256 # expected output: MobileViews_300000-522301.zip: OK
160
- ```
161
 
162
- If the output shows `OK`, the file has been downloaded correctly.
163
 
164
- If the verification result is not as expected, the download may be corrupted. Please try downloading the file again. If the issue persists, feel free to contact us at any time.
165
 
166
- ## How to Use
167
 
168
- You can unpack the `.zip` files using the `unzip` command in the terminal or any other unzipping tool.
 
169
 
170
- ```bash
171
- unzip MobileViews_0-150000.zip -d /path/to/extract/directory
172
- unzip MobileViews_150001-291197.zip -d /path/to/extract/directory
173
- unzip MobileViews_300000-522301.zip -d /path/to/extract/directory
174
- ```
175
- This will extract the contents to the specified directory.
176
 
177
  ## Citation
178
 
 
179
 
180
  ```
181
  @misc{gao2024mobileviewslargescalemobilegui,
@@ -187,4 +211,4 @@ To ensure the downloaded files are complete and correct, you can verify them in
187
  primaryClass={cs.HC},
188
  url={https://arxiv.org/abs/2409.14337},
189
  }
190
- ```
 
1
+
2
  ---
3
  language: [en]
4
  license: mit
 
20
  # MobileViews: A Large-Scale Mobile GUI Dataset
21
  [**Read the paper**](https://arxiv.org/abs/2409.14337)
22
 
23
+ **MobileViews** is a large-scale dataset designed to support research on mobile user interface (UI) analysis and mobile agents. The first version — **MobileViews-600K** — contains over **600,000** mobile UI screenshot-view hierarchy (VH) pairs, collected from approximately **20,000 apps** on the Google Play Store.
 
24
 
25
  ## Dataset Overview
26
 
27
+ The `zip` and `parquet` files with the same index contain the same screenshots and VH files, so you can choose whichever format you prefer to download and use.
28
 
29
+ - **`MobileViews_0-150000.zip`**, **`MobileViews_0-150000.parquet`** and **`MobileViews_index_0-150000.csv`**: The first set of screenshot-VH pairs, containing IDs from 0 to 150,000.
30
 
31
+ - **`MobileViews_150001-291197.zip`**, **`MobileViews_150001-291197.parquet`** and **`MobileViews_index_150001-291197.csv`**: The second set of screenshot-VH pairs, containing IDs from 150,001 to 291,197.
 
 
 
32
 
33
+ - **`MobileViews_300000-400000.zip`**, **`MobileViews_300000-400000.parquet`** and **`MobileViews_index_300000-400000.csv`**: The third set of screenshot-VH pairs, containing IDs from 300,000 to 400,000.
34
 
35
+ - **`MobileViews_400001-522301.zip`**, **`MobileViews_400001-522301.parquet`** and **`MobileViews_index_400001-522301.csv`**: The fourth set of screenshot-VH pairs, containing IDs from 400,001 to 522,301.
36
 
37
+ - **`AppMetadata.csv`**: Metadata for **15,000 apps** from the Google Play Store, retrieved in **June 2024**.
 
 
 
38
 
39
+ ### CSV and Parquet Column Descriptions
40
+
41
+ Both the CSV and Parquet files provide mappings between images and JSON view hierarchy files.
42
+
43
+ 1. **CSV Columns**
 
 
44
 
45
+ | Column | Description |
46
+ |--------------|-------------------------------------------|
47
+ | `Image File` | Filename of the screenshot (e.g., 0.jpg) |
48
+ | `JSON File` | Filename of the view hierarchy (e.g., 0.json) |
49
+
50
+ **Example:**
51
+ ```csv
52
+ Image File,JSON File
53
+ 300000.jpg,300000.json
54
+ 300001.jpg,300001.json
55
+ 300002.jpg,300002.json
56
+ ```
57
+ Here’s the updated section of the README for the MobileViews open-sourced dataset, modified to reflect that the Parquet columns are `image_content` and `json_content` instead of `image_path`:
58
+
59
+ ---
60
+
61
+ 2. **Parquet Columns**
62
+
63
+ | Column | Description |
64
+ |-----------------|--------------------------------------------------------------------------|
65
+ | `image_content` | Binary data representing the image file (e.g., screenshot in `.jpg` format) |
66
+ | `json_content` | JSON content representing the view hierarchy for the corresponding image |
67
+
68
+ **Example Data in Parquet:**
69
+
70
+ | image_content | json_content |
71
+ |------------------------|----------------------------------------------------------------------|
72
+ | Binary image data | `{"viewHierarchy": {"bounds": [0, 0, 1080, 1920], "viewClass": ...}` |
73
+ | Binary image data | `{"viewHierarchy": {"bounds": [0, 0, 1080, 1920], "viewClass": ...}` |
74
+ | Binary image data | `{"viewHierarchy": {"bounds": [0, 0, 1080, 1920], "viewClass": ...}` |
75
+
76
+ The **`image_content`** column contains the binary image data for each screenshot, which can be converted back into a `.jpg` image. The **`json_content`** column stores the JSON string with the view hierarchy details for each corresponding image.
77
 
78
  ### AppMetadata.csv Columns
79
 
 
90
  | `reviews` | Number of reviews |
91
  | `histogram` | Rating distribution |
92
  | `price` | App price |
93
+ | `free` | Whether the app is free (True/False) |
94
  | `offersIAP` | Offers in-app purchases (True/False) |
95
  | `inAppProductPrice` | In-app product price |
96
  | `developer` | Developer name |
 
105
  | `lastUpdatedOn` | Date of the latest update |
106
  | `appId` | Unique app identifier |
107
 
108
+ ## How to Use
109
+
110
+ ### Download via Hugging Face Python Library
111
+
112
+ **Install the library:**
113
+
114
+ ```bash
115
+ pip install huggingface_hub
116
+ ```
117
 
118
+ **Download specific files:**
119
 
120
+ ```python
121
+ from huggingface_hub import hf_hub_download
122
 
123
+ # Download specific files
124
+ hf_hub_download(repo_id="mllmTeam/MobileViews", filename="MobileViews_0-150000.parquet")
125
+ hf_hub_download(repo_id="mllmTeam/MobileViews", filename="MobileViews_0-150000.zip")
126
+ hf_hub_download(repo_id="mllmTeam/MobileViews", filename="AppMetadata.csv")
127
+ ```
128
 
129
+ **Download the entire repository:**
130
 
131
+ ```python
132
+ from huggingface_hub import snapshot_download
133
 
134
+ # Download the entire repository
135
+ snapshot_download(repo_id="mllmTeam/MobileViews")
136
+ ```
 
 
137
 
138
+ ### The usage of `zip` files
139
 
140
+ We recommend verifying the completeness and integrity of the files before unzipping them by following these steps.
141
 
142
+ **Example for `MobileViews_0-150000.zip`:**
 
 
 
 
143
 
144
+ ```bash
145
+ # Integrity check
146
+ zip -T MobileViews_0-150000.zip # Expected output: test of MobileViews_0-150000.zip OK
147
 
148
+ # Verify file counts (JSON and JPG)
149
+ unzip -l MobileViews_0-150000.zip | grep ".json" | wc -l # Expected output: 150001
150
+ unzip -l MobileViews_0-150000.zip | grep ".jpg" | wc -l # Expected output: 150001
151
 
152
+ # Verify file size
153
+ du -sh MobileViews_0-150000.zip # Expected output: 23G
 
 
 
 
 
154
 
155
+ # Verify SHA256 checksum
156
+ sha256sum -c MobileViews_0-150000.zip.sha256 # Expected output: MobileViews_0-150000.zip: OK
 
 
 
 
 
 
 
 
 
 
 
 
 
157
 
158
+ # Unzip
159
+ unzip MobileViews_0-150000.zip
160
+ ```
161
 
162
+ **Expected Outputs for Other ZIP Files:**
163
 
164
+ - **MobileViews_150001-291197.zip**:
165
+ - Integrity: `test of MobileViews_150001-291197.zip OK`
166
+ - JSON count: `141197`
167
+ - JPG count: `141197`
168
+ - Size: `36G`
169
+ - SHA256: `MobileViews_150001-291197.zip: OK`
170
 
171
+ - **MobileViews_300000-400000.zip**:
172
+ - Integrity: `test of MobileViews_300000-400000.zip OK`
173
+ - JSON count: `100001`
174
+ - JPG count: `100001`
175
+ - Size: `24G`
176
+ - SHA256: `MobileViews_300000-400000.zip: OK`
177
 
178
+ - **MobileViews_400001-522301.zip**:
179
+ - Integrity: `test of MobileViews_400001-522301.zip OK`
180
+ - JSON count: `122301`
181
+ - JPG count: `122301`
182
+ - Size: `13G`
183
+ - SHA256: `MobileViews_400001-522301.zip: OK`
184
 
185
+ ## The usage of `parquet` files
 
 
 
 
186
 
187
+ `Parquet` is an efficient, compressed columnar storage format optimized for large datasets. You can learn more about [Parquet](https://parquet.apache.org/docs).
188
 
189
+ We provide `useparquet.py`, which includes functions such as `check_row_count`, `save_n_images_and_jsons`, and `save_all_images_and_jsons` to help you quickly access the dataset.
190
 
191
+ If you need additional functionality, you can refer to the [`pyarrow`](https://arrow.apache.org/docs/python/generated/pyarrow.parquet.ParquetFile.html) documentation to explore more APIs.
192
 
193
+ ```bash
194
+ pip install pyarrow
195
 
196
+ # check the path and the function you need
197
+ python path/to/useparquet.py
198
+ ```
 
 
 
199
 
200
  ## Citation
201
 
202
+ If you use this dataset in your research, please cite our work as follows:
203
 
204
  ```
205
  @misc{gao2024mobileviewslargescalemobilegui,
 
211
  primaryClass={cs.HC},
212
  url={https://arxiv.org/abs/2409.14337},
213
  }
214
+ ```