Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
xuwx1
LightX2V
Commits
82661877
Commit
82661877
authored
Jul 11, 2025
by
helloyongyang
Browse files
update quant utils
parent
7423e576
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
lightx2v/utils/quant_utils.py
lightx2v/utils/quant_utils.py
+6
-1
No files found.
lightx2v/utils/quant_utils.py
View file @
82661877
import
torch
import
torch
from
qtorch.quant
import
float_quantize
from
loguru
import
logger
from
loguru
import
logger
try
:
from
qtorch.quant
import
float_quantize
except
Exception
:
logger
.
warning
(
"qtorch not found, please install qtorch.Please install qtorch (pip install qtorch)."
)
float_quantize
=
None
class
BaseQuantizer
(
object
):
class
BaseQuantizer
(
object
):
def
__init__
(
self
,
bit
,
symmetric
,
granularity
,
**
kwargs
):
def
__init__
(
self
,
bit
,
symmetric
,
granularity
,
**
kwargs
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment