LDJA commited on
Commit
a4bd7f1
1 Parent(s): 637a8f2
app/data/shakespeare_char/prepare.py CHANGED
@@ -49,21 +49,21 @@ print(f"val has {len(val_ids):,} tokens")
49
  train_ids = np.array(train_ids, dtype=np.uint16)
50
  val_ids = np.array(val_ids, dtype=np.uint16)
51
 
52
- permissions = 0o777
53
 
54
- file_path_dir = './data/shakespeare_char'
55
- os.chmod(file_path_dir, permissions)
56
 
57
- file_path_train = os.path.join(os.path.dirname(__file__), 'train.bin')
58
- file_path_val = os.path.join(os.path.dirname(__file__), 'val.bin')
59
 
60
  # open(file_path_train, 'wb')
61
  # open(file_path_val, 'wb')
62
 
63
  # permissions = 0o755
64
 
65
- os.chmod(file_path_train, permissions)
66
- os.chmod(file_path_val, permissions)
67
 
68
  train_ids.tofile(os.path.join(os.path.dirname(__file__), 'train.bin'))
69
  val_ids.tofile(os.path.join(os.path.dirname(__file__), 'val.bin'))
 
49
  train_ids = np.array(train_ids, dtype=np.uint16)
50
  val_ids = np.array(val_ids, dtype=np.uint16)
51
 
52
+ # permissions = 0o755
53
 
54
+ # file_path_dir = './data/shakespeare_char'
55
+ # os.chmod(file_path_dir, permissions)
56
 
57
+ # file_path_train = os.path.join(os.path.dirname(__file__), 'train.bin')
58
+ # file_path_val = os.path.join(os.path.dirname(__file__), 'val.bin')
59
 
60
  # open(file_path_train, 'wb')
61
  # open(file_path_val, 'wb')
62
 
63
  # permissions = 0o755
64
 
65
+ # os.chmod(file_path_train, permissions)
66
+ # os.chmod(file_path_val, permissions)
67
 
68
  train_ids.tofile(os.path.join(os.path.dirname(__file__), 'train.bin'))
69
  val_ids.tofile(os.path.join(os.path.dirname(__file__), 'val.bin'))