diff --git a/Dockerfile b/Dockerfile index 3e29f88..b517fe3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -42,7 +42,7 @@ RUN make dist FROM cebra-base # install the cebra wheel -ENV WHEEL=cebra-0.3.1-py2.py3-none-any.whl +ENV WHEEL=cebra-0.4.0-py2.py3-none-any.whl WORKDIR /build COPY --from=wheel /build/dist/${WHEEL} . RUN pip install --no-cache-dir ${WHEEL}'[dev,integrations,datasets]' diff --git a/Makefile b/Makefile index 16abfb9..9f94561 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -CEBRA_VERSION := 0.3.1 +CEBRA_VERSION := 0.4.0 dist: python3 -m pip install virtualenv diff --git a/PKGBUILD b/PKGBUILD index e4edb49..07fa3a1 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: Steffen Schneider pkgname=python-cebra _pkgname=cebra -pkgver=0.3.1 +pkgver=0.4.0 pkgrel=1 pkgdesc="Consistent Embeddings of high-dimensional Recordings using Auxiliary variables" url="https://cebra.ai" diff --git a/cebra/__init__.py b/cebra/__init__.py index ff9bc33..fd4cf58 100644 --- a/cebra/__init__.py +++ b/cebra/__init__.py @@ -66,7 +66,7 @@ import cebra.integrations.sklearn as sklearn -__version__ = "0.3.1" +__version__ = "0.4.0" __all__ = ["CEBRA"] __allow_lazy_imports = False __lazy_imports = {} diff --git a/reinstall.sh b/reinstall.sh index 9eb6d8c..778f98e 100755 --- a/reinstall.sh +++ b/reinstall.sh @@ -15,7 +15,7 @@ pip uninstall -y cebra # Get version info after uninstalling --- this will automatically get the # most recent version based on the source code in the current directory. # $(tools/get_cebra_version.sh) -VERSION=0.3.1 +VERSION=0.4.0 echo "Upgrading to CEBRA v${VERSION}" # Upgrade the build system (PEP517/518 compatible) diff --git a/tests/test_criterions.py b/tests/test_criterions.py index 24c4775..9d176be 100644 --- a/tests/test_criterions.py +++ b/tests/test_criterions.py @@ -259,10 +259,10 @@ def _reference_infonce(pos_dist, neg_dist): def test_similiarities(): - - ref = torch.randn(10, 3) - pos = torch.randn(10, 3) - neg = torch.randn(12, 3) + rng = torch.Generator().manual_seed(42) + ref = torch.randn(10, 3, generator = rng) + pos = torch.randn(10, 3, generator = rng) + neg = torch.randn(12, 3, generator = rng) pos_dist, neg_dist = _reference_dot_similarity(ref, pos, neg) pos_dist_2, neg_dist_2 = cebra_criterions.dot_similarity(ref, pos, neg)