vector-quantize-pytorch 1.6.6__tar.gz → 1.6.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/PKG-INFO +1 -1
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/setup.py +1 -1
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch/vector_quantize_pytorch.py +2 -2
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch.egg-info/PKG-INFO +1 -1
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/LICENSE +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/README.md +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/setup.cfg +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch/__init__.py +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch/random_projection_quantizer.py +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch/residual_vq.py +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch.egg-info/SOURCES.txt +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch.egg-info/dependency_links.txt +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch.egg-info/requires.txt +0 -0
- {vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch.egg-info/top_level.txt +0 -0
|
@@ -3,7 +3,7 @@ from setuptools import setup, find_packages
|
|
|
3
3
|
setup(
|
|
4
4
|
name = 'vector_quantize_pytorch',
|
|
5
5
|
packages = find_packages(),
|
|
6
|
-
version = '1.6.
|
|
6
|
+
version = '1.6.7',
|
|
7
7
|
license='MIT',
|
|
8
8
|
description = 'Vector Quantization - Pytorch',
|
|
9
9
|
long_description_content_type = 'text/markdown',
|
|
@@ -405,7 +405,7 @@ class EuclideanCodebook(nn.Module):
|
|
|
405
405
|
if self.affine_param:
|
|
406
406
|
self.update_affine(flatten, self.embed)
|
|
407
407
|
|
|
408
|
-
embed = self.embed if
|
|
408
|
+
embed = self.embed if self.learnable_codebook else self.embed.detach()
|
|
409
409
|
|
|
410
410
|
if self.affine_param:
|
|
411
411
|
codebook_std = self.codebook_variance.clamp(min = 1e-5).sqrt()
|
|
@@ -572,7 +572,7 @@ class CosineSimCodebook(nn.Module):
|
|
|
572
572
|
|
|
573
573
|
self.init_embed_(flatten)
|
|
574
574
|
|
|
575
|
-
embed = self.embed if
|
|
575
|
+
embed = self.embed if self.learnable_codebook else self.embed.detach()
|
|
576
576
|
|
|
577
577
|
dist = einsum('h n d, h c d -> h n c', flatten, embed)
|
|
578
578
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{vector_quantize_pytorch-1.6.6 → vector_quantize_pytorch-1.6.7}/vector_quantize_pytorch/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|