Datasets:
mb23
/

Languages:
English
License:
mickylan2367 commited on
Commit
c143885
·
1 Parent(s): 3501186

Update README

Browse files
Files changed (1) hide show
  1. README.md +37 -52
README.md CHANGED
@@ -11,6 +11,8 @@ size_categories:
11
 
12
  # Google/MusicCapsをスペクトログラムにしたデータ。
13
 
 
 
14
  ## Dataset information
15
  <table>
16
  <thead>
@@ -66,63 +68,45 @@ display(IPython.display.Audio(y_inv, rate=sr))
66
  * <font color="red">Subset <b>data 1300-1600</b> and <b>data 3400-3600</b> are not working now, so please get subset_name_list</n>
67
  those were removed first</font>.
68
  ### 1 : get information about this dataset:
69
- ```python
70
- # Extract dataset's information using huggingface API
71
- import requests
72
- headers = {"Authorization": f"Bearer {API token}"}
73
- API_URL = "https://datasets-server.huggingface.co/info?dataset=mb23%2FGraySpectrogram"
74
- def query():
75
- response = requests.get(API_URL, headers=headers)
76
- return response.json()
77
- data = query()
78
 
79
  # Make subset name list.
80
- subset_name_list = list()
81
- for dic in data["failed"]:
82
- subset_name_list.append(dic["config"])
83
- # print(dic["config"])
84
- subset_name_list = sorted(subset_name_list, key=natural_keys)
85
-
86
-
87
- remove_list = [
88
- "data 1300-1600",
89
- "data 3400-3600"
90
- ]
91
- for remove_dataset in remove_list:
92
- if remove_dataset in subset_name_list:
93
- subset_name_list.remove(remove_dataset)
94
- else:
95
- pass
96
- subset_name_list
97
 
 
98
  '''
99
- return subset name list. for example,
100
- ['data 0-200',
101
- 'data 200-600',
102
- 'data 600-1000',
103
- 'data 1000-1300',
104
- 'data 1600-2000',
105
- 'data 2000-2200',
106
- 'data 2200-2400',
107
- 'data 2400-2600',
108
- 'data 2600-2800',
109
- 'data 3000-3200',
110
- 'data 3200-3400',
111
- 'data 3600-3800',
112
- 'data 3800-4000',
113
- 'data 4000-4200',
114
- 'data 4200-4400',
115
- 'data 4400-4600',
116
- 'data 4600-4800',
117
- 'data 4800-5000',
118
- 'data 5000-5200',
119
- 'data 5200-5520']
120
  '''
121
- ```
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
122
 
123
- ### 2 : load all subset dataset:
124
- *
125
- ```python
126
  data = load_dataset("mb23/GraySpectrogram", subset_name_list[0])
127
  for subset in subset_name_list:
128
  # Confirm subset_list doesn't include "remove_list" datasets in the above cell.
@@ -139,7 +123,8 @@ data
139
  ```
140
 
141
 
142
- ### 3 : load dataset and change to dataloader:
 
143
  * You can use the code below:
144
  * <font color="red">...but (;・∀・)I don't know whether this code works efficiently, because I haven't tried this code so far</color>
145
  ```python
 
11
 
12
  # Google/MusicCapsをスペクトログラムにしたデータ。
13
 
14
+ * <font color="red">The dataset viwer of this repository is truncated, so maybe you should see <a href="https://huggingface.co/datasets/mb23/GraySpectrotram_example">this one</a> instaed.</font>
15
+
16
  ## Dataset information
17
  <table>
18
  <thead>
 
68
  * <font color="red">Subset <b>data 1300-1600</b> and <b>data 3400-3600</b> are not working now, so please get subset_name_list</n>
69
  those were removed first</font>.
70
  ### 1 : get information about this dataset:
 
 
 
 
 
 
 
 
 
71
 
72
  # Make subset name list.
73
+ * copy this~~
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
74
 
75
+ ```python
76
  '''
77
+ if you use GoogleColab, remove # to install packages below..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
78
  '''
79
+ #!pip install datasets
80
+ #!pip install huggingface-hub
81
+ #!huggingface-cli login
82
+ import datasets
83
+ from datasets import load_dataset
84
+
85
+ # make subset_name_list
86
+ subset_name_list = [
87
+ 'data 0-200',
88
+ 'data 200-600',
89
+ 'data 600-1000',
90
+ 'data 1000-1300',
91
+ 'data 1600-2000',
92
+ 'data 2000-2200',
93
+ 'data 2200-2400',
94
+ 'data 2400-2600',
95
+ 'data 2600-2800',
96
+ 'data 3000-3200',
97
+ 'data 3200-3400',
98
+ 'data 3600-3800',
99
+ 'data 3800-4000',
100
+ 'data 4000-4200',
101
+ 'data 4200-4400',
102
+ 'data 4400-4600',
103
+ 'data 4600-4800',
104
+ 'data 4800-5000',
105
+ 'data 5000-5200',
106
+ 'data 5200-5520'
107
+ ]
108
 
109
+ # load_all_datasets
 
 
110
  data = load_dataset("mb23/GraySpectrogram", subset_name_list[0])
111
  for subset in subset_name_list:
112
  # Confirm subset_list doesn't include "remove_list" datasets in the above cell.
 
123
  ```
124
 
125
 
126
+
127
+ ### 2 : load dataset and change to dataloader:
128
  * You can use the code below:
129
  * <font color="red">...but (;・∀・)I don't know whether this code works efficiently, because I haven't tried this code so far</color>
130
  ```python