meg-huggingface commited on
Commit
89f5615
1 Parent(s): 3b2722d

CPU support

Browse files
Files changed (1) hide show
  1. src/display/utils.py +3 -0
src/display/utils.py CHANGED
@@ -94,6 +94,7 @@ class WeightType(Enum):
94
  class Precision(Enum):
95
  float16 = ModelDetails("float16")
96
  bfloat16 = ModelDetails("bfloat16")
 
97
  #qt_8bit = ModelDetails("8bit")
98
  #qt_4bit = ModelDetails("4bit")
99
  #qt_GPTQ = ModelDetails("GPTQ")
@@ -104,6 +105,8 @@ class Precision(Enum):
104
  return Precision.float16
105
  if precision in ["torch.bfloat16", "bfloat16"]:
106
  return Precision.bfloat16
 
 
107
  #if precision in ["8bit"]:
108
  # return Precision.qt_8bit
109
  #if precision in ["4bit"]:
 
94
  class Precision(Enum):
95
  float16 = ModelDetails("float16")
96
  bfloat16 = ModelDetails("bfloat16")
97
+ float32 = ModelDetails("float32")
98
  #qt_8bit = ModelDetails("8bit")
99
  #qt_4bit = ModelDetails("4bit")
100
  #qt_GPTQ = ModelDetails("GPTQ")
 
105
  return Precision.float16
106
  if precision in ["torch.bfloat16", "bfloat16"]:
107
  return Precision.bfloat16
108
+ if precision in ["float32"]:
109
+ return Precision.float32
110
  #if precision in ["8bit"]:
111
  # return Precision.qt_8bit
112
  #if precision in ["4bit"]: