thak123 commited on
Commit
3f0a7d5
1 Parent(s): d2b8f1b

Update config.py

Browse files
Files changed (1) hide show
  1. config.py +7 -5
config.py CHANGED
@@ -1,6 +1,7 @@
1
  import transformers
2
  import os
3
  import torch
 
4
 
5
  MAX_LEN = 150 #256
6
  TRAIN_BATCH_SIZE = 8
@@ -12,14 +13,15 @@ EPOCHS = 5
12
  # print("hi")
13
  # hf_hub_download(repo_id="thak123/bert-emoji-latvian-twitter-classifier", filename="model.bin",local_dir="./")
14
 
15
- from huggingface_hub import snapshot_download
16
- snapshot_download(repo_id="thak123/bert-emoji-latvian-twitter-classifier", allow_patterns="*.bin")
17
 
18
 
19
  # import requests
20
- # URL = "https://huggingface.co/thak123/bert-emoji-latvian-twitter-classifier/resolve/main/model.bin"
21
- # response = requests.get(URL)
22
- # open("model.bin", "wb").write(response.content)
 
23
 
24
  DATASET_LOCATION = "" #
25
  MODEL_PATH = "model.bin"
 
1
  import transformers
2
  import os
3
  import torch
4
+ import requests
5
 
6
  MAX_LEN = 150 #256
7
  TRAIN_BATCH_SIZE = 8
 
13
  # print("hi")
14
  # hf_hub_download(repo_id="thak123/bert-emoji-latvian-twitter-classifier", filename="model.bin",local_dir="./")
15
 
16
+ # from huggingface_hub import snapshot_download
17
+ # snapshot_download(repo_id="thak123/bert-emoji-latvian-twitter-classifier", allow_patterns="*.bin")
18
 
19
 
20
  # import requests
21
+ URL = "https://huggingface.co/thak123/bert-emoji-latvian-twitter-classifier/resolve/main/model.bin"
22
+ response = requests.get(URL)
23
+ open("model.bin", "wb").write(response.content)
24
+
25
 
26
  DATASET_LOCATION = "" #
27
  MODEL_PATH = "model.bin"