admin commited on
Commit
23c954e
·
1 Parent(s): 48c3a99
Files changed (2) hide show
  1. CNPM.py +3 -6
  2. README.md +1 -1
CNPM.py CHANGED
@@ -38,12 +38,9 @@ _TYPE = [
38
  "Heptatonic_Yanyue",
39
  ]
40
 
41
- _DBNAME = os.path.basename(__file__).split(".")[0]
42
-
43
- _DOMAIN = f"https://www.modelscope.cn/api/v1/datasets/ccmusic-database/{_DBNAME}/repo?Revision=master&FilePath=data"
44
-
45
- _HOMEPAGE = f"https://www.modelscope.cn/datasets/ccmusic-database/{_DBNAME}"
46
 
 
47
 
48
  _URLS = {
49
  "audio": f"{_DOMAIN}/audio.zip",
@@ -90,6 +87,7 @@ class CNPM(datasets.GeneratorBasedBuilder):
90
  def _val_of_key(self, labels: pd.DataFrame, key: str, col: str):
91
  try:
92
  return labels.loc[key][col]
 
93
  except KeyError:
94
  return ""
95
 
@@ -136,7 +134,6 @@ class CNPM(datasets.GeneratorBasedBuilder):
136
  )
137
 
138
  random.shuffle(dataset)
139
-
140
  return [
141
  datasets.SplitGenerator(
142
  name=datasets.Split.TRAIN,
 
38
  "Heptatonic_Yanyue",
39
  ]
40
 
41
+ _HOMEPAGE = f"https://www.modelscope.cn/datasets/ccmusic-database/{os.path.basename(__file__)[:-3]}"
 
 
 
 
42
 
43
+ _DOMAIN = f"{_HOMEPAGE}/resolve/master/data"
44
 
45
  _URLS = {
46
  "audio": f"{_DOMAIN}/audio.zip",
 
87
  def _val_of_key(self, labels: pd.DataFrame, key: str, col: str):
88
  try:
89
  return labels.loc[key][col]
90
+
91
  except KeyError:
92
  return ""
93
 
 
134
  )
135
 
136
  random.shuffle(dataset)
 
137
  return [
138
  datasets.SplitGenerator(
139
  name=datasets.Split.TRAIN,
README.md CHANGED
@@ -139,7 +139,7 @@ for data in dataset:
139
 
140
  ## Maintenance
141
  ```bash
142
- GIT_LFS_SKIP_SMUDGE=1 git clone [email protected]:datasets/ccmusic-database/CNPM
143
  cd CNPM
144
  ```
145
 
 
139
 
140
  ## Maintenance
141
  ```bash
142
+ git clone [email protected]:datasets/ccmusic-database/CNPM
143
  cd CNPM
144
  ```
145