yuukicammy
commited on
Commit
·
d50478c
1
Parent(s):
78a7c9c
Added description.
Browse files
README.md
CHANGED
@@ -1,3 +1,91 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# MIT-Adobe FiveK Dataset
|
2 |
+
|
3 |
+
The MIT-Adobe FiveK Dataset [[1]]( #references ) is a publicly available dataset providing the following items.
|
4 |
+
1. 5,000 RAW images in DNG format
|
5 |
+
2. retouched images of each RAW image by five experts in TIFF format (25,000 images, 16 bits per channel, ProPhoto RGB color space, and lossless compression)
|
6 |
+
3. semantic information about each image
|
7 |
+
The dataset was created by MIT and Adobe Systems, Inc., and is intended to provide a diverse and challenging set of images for testing image processing algorithms. The images were selected to represent a wide range of scenes, including landscapes, portraits, still lifes, and architecture. The images also vary in terms of lighting conditions, color balance, and exposure.
|
8 |
+
In practice, this dataset is often used after RAW images have undergone various processing steps. For example, RAW images are developed by adding noise, overexposure, and underexposure to emulate camera errors.
|
9 |
+
However, the officially provided dataset has a complex structure and is difficult to handle. This repository provides tools to easily download and use the datasets.
|
10 |
+
|
11 |
+
## Official Website
|
12 |
+
|
13 |
+
[MIT-Adobe FiveK Dataset](https://data.csail.mit.edu/graphics/fivek/)
|
14 |
+
|
15 |
+
## License
|
16 |
+
|
17 |
+
- [LicenseAdobe.txt](https://data.csail.mit.edu/graphics/fivek/legal/LicenseAdobe.txt) covers files listed in [filesAdobe.txt](https://data.csail.mit.edu/graphics/fivek/legal/filesAdobe.txt)
|
18 |
+
- [LicenseAdobeMIT.txt](https://data.csail.mit.edu/graphics/fivek/legal/LicenseAdobeMIT.txt) covers files listed in [filesAdobeMIT.txt](https://data.csail.mit.edu/graphics/fivek/legal/filesAdobeMIT.txt)
|
19 |
+
|
20 |
+
## Data Samples
|
21 |
+
|
22 |
+
|Raw (DNG)|Expert A|Expert B|Expert C|Expert D|Expert E|Categories|Camera Model|
|
23 |
+
|---|---|---|---|---|---|---|---|
|
24 |
+
|[a0001-jmac_</br >DSC1459.dng](https://data.csail.mit.edu/graphics/fivek/img/dng/a0001-jmac_DSC1459.dng)|![tiff16_a/a0001-jmac_DSC1459](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a0001-jmac_DSC1459_A.jpg)|![tiff16_b/a0001-jmac_DSC1459](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a0001-jmac_DSC1459_B.jpg)|![tiff16_c/a0001-jmac_DSC1459](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a0001-jmac_DSC1459_C.jpg)|![tiff16_d/a0001-jmac_DSC1459](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a0001-jmac_DSC1459_D.jpg)|![tiff16_e/a0001-jmac_DSC1459](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a0001-jmac_DSC1459_E.jpg)|{"location":"outdoor","time": "day","light": "sun_sky","subject": "nature"}|Nikon D70|
|
25 |
+
|[a1384-dvf_095.dng](https://data.csail.mit.edu/graphics/fivek/img/dng/a1384-dvf_095.dng)|![tiff16_a/a1384-dvf_095](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a1384-dvf_095_A.jpg)|![tiff16_b/a1384-dvf_095](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a1384-dvf_095_B.jpg)|![tiff16_c/a1384-dvf_095](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a1384-dvf_095_C.jpg)|![tiff16_d/a1384-dvf_095](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a1384-dvf_095_D.jpg)|![tiff16_e/a1384-dvf_095](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a1384-dvf_095_E.jpg)|{ "location": "outdoor", "time": "day", "light": "sun_sky", "subject": "nature" }|Leica M8|
|
26 |
+
|[a4607-050801_</br >080948__</br >I2E5512.dng](https://data.csail.mit.edu/graphics/fivek/img/dng/a4607-050801_080948__I2E5512.dng)|![tiff16_a/a4607-050801_080948__I2E5512](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a4607-050801_080948__I2E5512_A.jpg)|![tiff16_b/a4607-050801_080948__I2E5512](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a4607-050801_080948__I2E5512_B.jpg)|![tiff16_c/a4607-050801_080948__I2E5512](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a4607-050801_080948__I2E5512_C.jpg)|![tiff16_d/a4607-050801_080948__I2E5512](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a4607-050801_080948__I2E5512_D.jpg)|![tiff16_e/a4607-050801_080948__I2E5512](https://raw.githubusercontent.com/yuukicammy/mit-adobe-fivek-dataset/master/data/thumbnails/a4607-050801_080948__I2E5512_E.jpg)|{ "location": "indoor", "time": "day", "light": "artificial", "subject": "people" }|Canon EOS-1D Mark II|
|
27 |
+
|
28 |
+
# References
|
29 |
+
|
30 |
+
```
|
31 |
+
@inproceedings{fivek,
|
32 |
+
author = "Vladimir Bychkovsky and Sylvain Paris and Eric Chan and Fr{\'e}do Durand",
|
33 |
+
title = "Learning Photographic Global Tonal Adjustment with a Database of Input / Output Image Pairs",
|
34 |
+
booktitle = "The Twenty-Fourth IEEE Conference on Computer Vision and Pattern Recognition",
|
35 |
+
year = "2011"
|
36 |
+
}
|
37 |
+
```
|
38 |
+
|
39 |
+
# Code
|
40 |
+
|
41 |
+
[GitHub repository](https://github.com/yuukicammy/mit-adobe-fivek-dataset) provides tools to download and use MIT-Adobe FiveK Dataset in a machine learning friendly manner.
|
42 |
+
You can download the dataset with a single line of Python code. Also, you can use Pytorch's DetaLoader to iteratively retrieve data for your own use.
|
43 |
+
The processing can be easily accomplished with multiprocessing with Pytorch's DataLoader!
|
44 |
+
|
45 |
+
## Requirements
|
46 |
+
- Python 3.7 or greater
|
47 |
+
- Pytorch 2.X
|
48 |
+
- tqdm
|
49 |
+
- urllib3
|
50 |
+
|
51 |
+
## Usage
|
52 |
+
|
53 |
+
You can use as follows.
|
54 |
+
|
55 |
+
<span style="color:red">
|
56 |
+
NOTE: For DataLoader, MUST set `batch_size` to `None` to disable automatic batching.
|
57 |
+
</span>
|
58 |
+
|
59 |
+
```python
|
60 |
+
from torch.utils.data.dataloader import DataLoader
|
61 |
+
from dataset.fivek import MITAboveFiveK
|
62 |
+
|
63 |
+
metadata_loader = DataLoader(
|
64 |
+
MITAboveFiveK(root="path-to-dataset-root", split="train", download=True, experts=["a"]),
|
65 |
+
batch_size=None, num_workers=2)
|
66 |
+
|
67 |
+
for item in metadata_loader:
|
68 |
+
# Processing as you want.
|
69 |
+
# Add noise, overexpose, underexpose, etc.
|
70 |
+
print(item["files"]["dng"])
|
71 |
+
```
|
72 |
+
|
73 |
+
## Example
|
74 |
+
|
75 |
+
Please see [sample code](https://github.com/yuukicammy/mit-adobe-fivek-dataset/blob/master/sample_process.py) .
|
76 |
+
|
77 |
+
## API
|
78 |
+
|
79 |
+
CLASS MITAboveFiveK(torch.utils.data.dataset.Dataset)
|
80 |
+
- - -
|
81 |
+
MITAboveFiveK(root: str, split: str, download: bool = False, experts: List[str] = None) -> None
|
82 |
+
|
83 |
+
- root (str):
|
84 |
+
The root directory where the MITAboveFiveK directory exists or to be created.
|
85 |
+
- split (str):
|
86 |
+
One of {'train', 'val', 'test', 'debug'}. 'debug' uses only 9 data contained in 'train'.
|
87 |
+
- download (bool):
|
88 |
+
If True, downloads the dataset from the official urls. Files that already exist locally will skip the download. Defaults to False.
|
89 |
+
- experts (List[str]):
|
90 |
+
List of {'a', 'b', 'c', 'd', 'e'}. 'a' means 'Expert A' in the [website](https://data.csail.mit.edu/graphics/fivek/ ). If None or empty list, no expert data is used. Defaults to None.
|
91 |
+
|