brettrenfer commited on
Commit
6cef258
·
verified ·
1 Parent(s): 343a8a6

Update dataset card

Browse files
Files changed (1) hide show
  1. README.md +181 -21
README.md CHANGED
@@ -1,29 +1,189 @@
1
  ---
2
  license: cc0-1.0
3
- pretty_name: The Met Open Access
4
- tags:
5
- - art
6
- - museum
7
- - cultural-heritage
8
- - image
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9
  configs:
10
- - config_name: default
11
- data_files:
12
- - split: train
13
- path: default/train/openaccess-*.parquet
14
  ---
 
 
15
 
16
- # metmuseum/openaccess
17
 
18
- Public-domain artworks from The Metropolitan Museum of Art's Open Access initiative,
19
- joined with image bytes from the Collection API. Generated by the
20
- [`et-openaccess-embeddings`](https://github.com/metmuseum/et-openaccess-embeddings) toolset.
21
 
22
- - **Source metadata:** <https://github.com/metmuseum/openaccess>
23
- - **Source images / extra fields:** <https://collectionapi.metmuseum.org/public/collection/v1/objects/{id}>
24
- - **License:** CC0 1.0 (per The Met's Open Access program)
25
- - **Shards:** 52
26
 
27
- Each row carries the full set of fields returned by the Collection API
28
- (`primaryImage`, `title`, `artistDisplayName`, `creditLine`, `objectURL`, `tags`, ...)
29
- and an `image` struct `{bytes, path}` that the HF dataset viewer renders directly.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: cc0-1.0
3
+ language:
4
+ - en
5
+ pretty_name: The Metropolitan Museum of Art - Open Access CSV
6
+ dataset_info:
7
+ features:
8
+ - name: objectID
9
+ dtype: int64
10
+ - name: isHighlight
11
+ dtype: bool
12
+ - name: accessionNumber
13
+ dtype: string
14
+ - name: accessionYear
15
+ dtype: string
16
+ - name: isPublicDomain
17
+ dtype: bool
18
+ - name: primaryImage
19
+ dtype: string
20
+ - name: primaryImageSmall
21
+ dtype: string
22
+ - name: additionalImages
23
+ dtype: string
24
+ - name: constituents
25
+ dtype: string
26
+ - name: department
27
+ dtype: string
28
+ - name: objectName
29
+ dtype: string
30
+ - name: title
31
+ dtype: string
32
+ - name: culture
33
+ dtype: string
34
+ - name: period
35
+ dtype: string
36
+ - name: dynasty
37
+ dtype: string
38
+ - name: reign
39
+ dtype: string
40
+ - name: portfolio
41
+ dtype: string
42
+ - name: artistRole
43
+ dtype: string
44
+ - name: artistPrefix
45
+ dtype: string
46
+ - name: artistDisplayName
47
+ dtype: string
48
+ - name: artistDisplayBio
49
+ dtype: string
50
+ - name: artistSuffix
51
+ dtype: string
52
+ - name: artistAlphaSort
53
+ dtype: string
54
+ - name: artistNationality
55
+ dtype: string
56
+ - name: artistBeginDate
57
+ dtype: string
58
+ - name: artistEndDate
59
+ dtype: string
60
+ - name: artistGender
61
+ dtype: string
62
+ - name: artistWikidata_URL
63
+ dtype: string
64
+ - name: artistULAN_URL
65
+ dtype: string
66
+ - name: objectDate
67
+ dtype: string
68
+ - name: objectBeginDate
69
+ dtype: int64
70
+ - name: objectEndDate
71
+ dtype: int64
72
+ - name: medium
73
+ dtype: string
74
+ - name: dimensions
75
+ dtype: string
76
+ - name: measurements
77
+ dtype: string
78
+ - name: creditLine
79
+ dtype: string
80
+ - name: geographyType
81
+ dtype: string
82
+ - name: city
83
+ dtype: string
84
+ - name: state
85
+ dtype: string
86
+ - name: county
87
+ dtype: string
88
+ - name: country
89
+ dtype: string
90
+ - name: region
91
+ dtype: string
92
+ - name: subregion
93
+ dtype: string
94
+ - name: locale
95
+ dtype: string
96
+ - name: locus
97
+ dtype: string
98
+ - name: excavation
99
+ dtype: string
100
+ - name: river
101
+ dtype: string
102
+ - name: classification
103
+ dtype: string
104
+ - name: rightsAndReproduction
105
+ dtype: string
106
+ - name: linkResource
107
+ dtype: float64
108
+ - name: metadataDate
109
+ dtype: string
110
+ - name: repository
111
+ dtype: string
112
+ - name: objectURL
113
+ dtype: string
114
+ - name: tags
115
+ dtype: string
116
+ - name: objectWikidata_URL
117
+ dtype: string
118
+ - name: isTimelineWork
119
+ dtype: bool
120
+ - name: GalleryNumber
121
+ dtype: string
122
+ - name: image
123
+ dtype: image
124
  configs:
125
+ - config_name: default
126
+ data_files:
127
+ - split: train
128
+ path: default/train/openaccess-*.parquet
129
  ---
130
+ The Metropolitan Museum of Art Open Access on HuggingFace
131
+ ===================
132
 
133
+ The [Metropolitan Museum of Art](http://www.metmuseum.org) presents over 5,000 years of art from around the world for everyone to experience and enjoy. The Museum lives in two iconic sites in New York City-The Met Fifth Avenue and The Met Cloisters. Millions of people also take part in The Met experience online.
134
 
135
+ Since it was founded in 1870, The Met has always aspired to be more than a treasury of rare and beautiful objects. Every day, art comes alive in the Museum's galleries and through its exhibitions and events, revealing both new ideas and unexpected connections across time and across cultures.
 
 
136
 
137
+ The Metropolitan Museum of Art provides select datasets of information on more than 470,000 artworks in its Collection for unrestricted commercial and noncommercial use. To the extent possible under law, The Metropolitan Museum of Art has waived all rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law, using [Creative Commons Zero](https://creativecommons.org/publicdomain/zero/1.0/). This work is published from: The United States Of America. You can also find the text of the CC Zero deed in the file [LICENSE](https://huggingface.co/datasets/metmuseum/openaccess/blob/main/LICENSE.txt) in this repository. These select datasets are now available for use in any media without permission or fee; they also include identifying data for artworks under copyright. The datasets support the search, use, and interaction with the Museum's collection.
 
 
 
138
 
139
+ ## Documentation in progress
140
+ This data is provided “as is” and you use this data at your own risk. The Metropolitan Museum of Art makes no representations or warranties of any kind. Documentation of the Museum’s collection is an ongoing process and parts of the datasets are incomplete.
141
+
142
+ We plan to update the datasets with new and revised information on a regular basis. You are advised to regularly update your copy of the datasets to ensure you are using the best available information.
143
+
144
+ ## Pull requests
145
+ Because these datasets are generated from our internal database, we do not accept pull requests. If you have identified errors or have extra information to share, please email us at openaccess@metmuseum.org and we will forward to the appropriate department for review.
146
+
147
+ ## Attribution
148
+ Please consider attributing or citing The Metropolitan Museum of Art's CC0 select datasets, especially with respect to research or publication. Attribution supports efforts to release other datasets in the future. It also reduces the amount of "orphaned data," helping to retain source links.
149
+
150
+ ## Do not misrepresent the dataset
151
+ Do not mislead others or misrepresent the datasets or their source. You must not use The Metropolitan Museum of Art’s trademarks or otherwise claim or imply that the Museum or any other third party endorses you or your use of the dataset.
152
+
153
+ Whenever you transform, translate or otherwise modify the dataset, you must make it clear that the resulting information has been modified. If you enrich or otherwise modify the dataset, consider publishing the derived dataset without reuse restrictions.
154
+
155
+ The writers of these guidelines thank the [The Museum of Modern Art](https://www.moma.org/), the [Tate](https://www.tate.org.uk/), [Cooper-Hewitt](https://www.cooperhewitt.org/), and [Europeana](https://www.europeana.eu/en).
156
+
157
+ ## Additional usage guidelines
158
+ For more details on how to use images of artworks in The Metropolitan Museum of Art’s collection, please visit our [Open Access](http://www.metmuseum.org/about-the-met/policies-and-documents/image-resources) page.
159
+
160
+ ---------------------
161
+ ## Notes on HuggingFace-specific Data
162
+ * This dataset includes images in the ```url``` column, and additional data generated by [img2dataset](https://github.com/rom1504/img2dataset)
163
+ * We include all data, including rows that do *not* have images
164
+ * You can filter by "Is Public Domain=True" or is "url" blank
165
+ * These images are the ```primaryImageSmall``` field via our API, i.e., they are not full-res, and have some compression
166
+ * See below and our [Collection API](https://metmuseum.github.io/) if you would like to recreate the data and include larger images (```primaryImage```) or additional views (```additionalImages```)
167
+ * This would require edits to ```add_images.py```
168
+
169
+ ## Updating or recreating the CSV + images
170
+ Right now, this is a manual process. This will eventually be automated.
171
+
172
+ 1. Download or clone the CSV from our [github](https://github.com/metmuseum/openaccess)
173
+ 2. (Optional) Create a compressed CSV
174
+ * Since some operating systems or machines choke on our huge CSV, it can be convenient to compress the file.
175
+ * Easiest: ```gzip MetObjects.csv```
176
+ 3. Process the CSV
177
+ * Right now, there are many ```\n``` characters in the CSV. Some Python interpreters don't like this.
178
+ * Use ```clean.py``` to create a cleaned version, now called ```metadata.csv.gz```
179
+ 4. (Optional) add images to the CSV
180
+ * Run ```add_images.py```
181
+ * It will take a while
182
+ * CAUTION: be very careful with the ```do_verify``` variable. Some networks do SSL redirects that Python does not like. Disabling this will not verify SSL certs. This is a quick band-aid to bypass this, but totally unsafe.
183
+ 5. Install [img2dataset](https://github.com/rom1504/img2dataset)
184
+ * ```pip install img2dataset```
185
+ 6. Run ```img2dataset``` with the following options:
186
+ * ```img2dataset --processes_count 10 --thread_count 64 --url_list "cleaned_metadata_images.csv.gz" --input_format "csv.gz" --output_format "parquet" --output_folder "data/train" --url_col "primaryImageSmall" --disable_all_reencoding "True" --max_shard_retry 10 --retries 10 --save_additional_columns "['Is Highlight', 'Is Timeline Work', 'Is Public Domain', 'Object ID', 'Gallery Number', 'Department', 'AccessionYear', 'Object Name', 'Title', 'Culture', 'Period', 'Dynasty', 'Reign', 'Portfolio', 'Constituent ID', 'Artist Role', 'Artist Prefix', 'Artist Display Name', 'Artist Display Bio', 'Artist Suffix', 'Artist Alpha Sort', 'Artist Nationality', 'Artist Begin Date', 'Artist End Date', 'Artist Gender', 'Artist ULAN URL', 'Artist Wikidata URL', 'Object Date', 'Object Begin Date', 'Object End Date', 'Medium', 'Dimensions', 'Credit Line', 'Geography Type', 'City', 'State', 'County', 'Country', 'Region', 'Subregion', 'Locale', 'Locus', 'Excavation', 'River', 'Classification', 'Rights and Reproduction', 'Link Resource', 'Object Wikidata URL', 'Metadata Date', 'Repository', 'Tags', 'Tags AAT URL', 'Tags Wikidata URL']"```
187
+ * See img2dataset's docs for details on the above. You may want to remove the ```disable_all_reencoding``` option... As-is, it does not downsize or compress images at all
188
+ * This will take some time
189
+ 7. Voila! You should have a large data folder with many json and parquet files. You should be able to load this in the huggingface client library as a dataset, etc.