Skip to content
This repository has been archived by the owner on Apr 10, 2024. It is now read-only.

Commit

Permalink
Fix all remaining Python 2 incompatibilities. Ahem.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ludwig Schubert committed Nov 29, 2018
1 parent dda4605 commit c095b85
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lucid/modelzoo/aligned_activations.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from lucid.misc.io import load

import numpy as np
from functools import lru_cache
from cachetools.func import lru_cache

PATH_TEMPLATE = "gs://modelzoo/aligned-activations/{}/{}-{:05d}-of-01000.npy"
PAGE_SIZE = 10000
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

from setuptools import setup, find_packages

version = "0.3.5"
version = "0.3.6"

test_deps = ["future", "twine", "pytest", "pytest-mock", "python-coveralls"]

Expand Down Expand Up @@ -64,6 +64,7 @@
"pyopengl",
"click",
"filelock",
"cachetools"
],
tests_require=test_deps,
extras_require=extras,
Expand Down
Binary file modified tests/fixtures/arrays.npz
Binary file not shown.
2 changes: 1 addition & 1 deletion tests/modelzoo/test_vision_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def test_model_properties(name, model_class):
assert hasattr(model_class, "layers")
assert len(model_class.layers) > 0
last_layer = model_class.layers[-1]
assert last_layer['type'] == 'dense'
assert 'dense' in last_layer.tags
assert type(last_layer) == Layer
assert last_layer.model_class == model_class
assert hasattr(model_class, "name")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,6 @@ def test_aligned_activation_atlas():
atlasses = aligned_activation_atlas(
model1, layer1, model2, layer2, number_activations=subset
)
path = f"tests/recipes/results/activation_atlas/aligned_atlas-{index}-of-{len(atlasses)}.jpg"
path = "tests/recipes/results/activation_atlas/aligned_atlas-{}-of-{}.jpg".format(index, len(atlasses))
for index, atlas in enumerate(atlasses):
save(atlas, path)

0 comments on commit c095b85

Please sign in to comment.