Zeel commited on
Commit
189e1de
·
1 Parent(s): 68f1499

patch harder!

Browse files
Files changed (1) hide show
  1. app.py +3 -0
app.py CHANGED
@@ -5,8 +5,11 @@ def fake_is_available():
5
  return True
6
  def fake_device_capability():
7
  return (8, 0)
 
 
8
  sys.modules["torch"].cuda.is_available = fake_is_available
9
  sys.modules["torch"].cuda.get_device_capability = fake_device_capability
 
10
 
11
  import streamlit as st
12
  from unsloth.chat_templates import get_chat_template, CHAT_TEMPLATES
 
5
  return True
6
  def fake_device_capability():
7
  return (8, 0)
8
+ def fake_current_device():
9
+ return 0
10
  sys.modules["torch"].cuda.is_available = fake_is_available
11
  sys.modules["torch"].cuda.get_device_capability = fake_device_capability
12
+ sys.modules["torch"].cuda.current_device = fake_current_device
13
 
14
  import streamlit as st
15
  from unsloth.chat_templates import get_chat_template, CHAT_TEMPLATES