Explorar el Código

black & isort

dbaranchuk hace 3 años
padre
commit
02619d307d
Se han modificado 1 ficheros con 2 adiciones y 2 borrados
  1. 2 2
      src/utils/convert_8bit.py

+ 2 - 2
src/utils/convert_8bit.py

@@ -1,5 +1,5 @@
-import torch
 import bitsandbytes as bnb
+import torch
 
 
 def replace_8bit_linear(model, threshold=6.0):
@@ -31,4 +31,4 @@ def replace_8bit_linear(model, threshold=6.0):
                 has_fp16_weights=False,
                 threshold=threshold,
             ).to(model._modules[n].weight.device)
-    return model
+    return model