AbdelrehmanFouad commited on
Commit
9a2308c
·
verified ·
1 Parent(s): a01794f

Upload debug_base_output.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. debug_base_output.py +4 -1
debug_base_output.py CHANGED
@@ -1,3 +1,7 @@
 
 
 
 
1
  import torch
2
  import json
3
  from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
@@ -6,7 +10,6 @@ model_id = "AbdelrehmanFouad/t5-efficient-base-usdjpy-forecaster"
6
  tokenizer = AutoTokenizer.from_pretrained(model_id)
7
  model = AutoModelForSeq2SeqLM.from_pretrained(model_id, device_map="auto", torch_dtype=torch.float32)
8
 
9
- # Sample input similar to training
10
  input_data = {
11
  "context_window": [150.0] * 168,
12
  "macro_events": []
 
1
+
2
+ # /// script
3
+ # dependencies = ["torch", "transformers", "accelerate"]
4
+ # ///
5
  import torch
6
  import json
7
  from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
 
10
  tokenizer = AutoTokenizer.from_pretrained(model_id)
11
  model = AutoModelForSeq2SeqLM.from_pretrained(model_id, device_map="auto", torch_dtype=torch.float32)
12
 
 
13
  input_data = {
14
  "context_window": [150.0] * 168,
15
  "macro_events": []