system HF staff commited on
Commit
a1f248c
1 Parent(s): 1419248

Update files from the datasets library (from 1.18.0)

Browse files

Release notes: https://github.com/huggingface/datasets/releases/tag/1.18.0

Files changed (1) hide show
  1. generate_dummy.py +3 -3
generate_dummy.py CHANGED
@@ -3,7 +3,7 @@ from pathlib import Path
3
 
4
  import fsspec as fs
5
  import requests
6
- from oscar import _BASE_CHECKSUM_FILE_NAME, Oscar
7
 
8
 
9
  N_EXAMPLES = 2
@@ -11,7 +11,7 @@ N_EXAMPLES = 2
11
  if __name__ == "__main__":
12
 
13
  for i, config in enumerate(Oscar.BUILDER_CONFIGS):
14
- print(f"Loading config '{config.name}' ({i + 1}/{len(Oscar.BUILDER_CONFIGS)})")
15
 
16
  # Get data url
17
  checksum_filename = _BASE_CHECKSUM_FILE_NAME.format(language=config.language)
@@ -42,6 +42,6 @@ if __name__ == "__main__":
42
  root_dir = str(dummy_data_dir.parent)
43
  base_name = str(dummy_data_dir)
44
  base_dir = "dummy_data"
45
- print(f"Compressing dummy data folder to '{base_name}.zip'")
46
  shutil.make_archive(base_name, "zip", root_dir, base_dir)
47
  shutil.rmtree(base_name)
 
3
 
4
  import fsspec as fs
5
  import requests
6
+ from oscar import _BASE_CHECKSUM_FILE_NAME, Oscar, logger
7
 
8
 
9
  N_EXAMPLES = 2
 
11
  if __name__ == "__main__":
12
 
13
  for i, config in enumerate(Oscar.BUILDER_CONFIGS):
14
+ logger.info(f"Loading config '{config.name}' ({i + 1}/{len(Oscar.BUILDER_CONFIGS)})")
15
 
16
  # Get data url
17
  checksum_filename = _BASE_CHECKSUM_FILE_NAME.format(language=config.language)
 
42
  root_dir = str(dummy_data_dir.parent)
43
  base_name = str(dummy_data_dir)
44
  base_dir = "dummy_data"
45
+ logger.info(f"Compressing dummy data folder to '{base_name}.zip'")
46
  shutil.make_archive(base_name, "zip", root_dir, base_dir)
47
  shutil.rmtree(base_name)