iioSnail commited on
Commit
2e14c11
·
verified ·
1 Parent(s): d3a1af5
Files changed (1) hide show
  1. csc_model.py +1 -3
csc_model.py CHANGED
@@ -8,7 +8,6 @@ from typing import List
8
  import numpy as np
9
  import torch
10
  from huggingface_hub import hf_hub_download
11
- from huggingface_hub.file_download import http_user_agent
12
  from torch import nn
13
  from torch.nn import functional as F
14
  from transformers import BertPreTrainedModel, BertModel
@@ -29,8 +28,7 @@ def download_file(filename: str, path: Path):
29
  hf_hub_download(
30
  "iioSnail/ChineseBERT-for-csc",
31
  filename,
32
- local_dir=cache_path,
33
- user_agent=http_user_agent(),
34
  )
35
  time.sleep(0.2)
36
 
 
8
  import numpy as np
9
  import torch
10
  from huggingface_hub import hf_hub_download
 
11
  from torch import nn
12
  from torch.nn import functional as F
13
  from transformers import BertPreTrainedModel, BertModel
 
28
  hf_hub_download(
29
  "iioSnail/ChineseBERT-for-csc",
30
  filename,
31
+ local_dir=cache_path
 
32
  )
33
  time.sleep(0.2)
34