Skip to content

Commit

Permalink
Merge pull request #12 from elephant-track/dev
Browse files Browse the repository at this point in the history
ELEPHANT server v0.3.2 -> v0.3.3
  • Loading branch information
ksugar authored Dec 8, 2021
2 parents 50e3e22 + 3a87595 commit cfb4caa
Show file tree
Hide file tree
Showing 9 changed files with 153 additions and 127 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM pytorch/pytorch:1.4-cuda10.1-cudnn7-runtime
FROM pytorch/pytorch:1.10.0-cuda11.3-cudnn8-runtime
# Modified from https://github.com/tiangolo/uwsgi-nginx-flask-docker (Apache license)

LABEL maintainer="Ko Sugawara <[email protected]>"
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ help:

ELEPHANT_GPU?=0
ELEPHANT_WORKSPACE?=${PWD}/workspace
ELEPHANT_IMAGE_NAME?=elephant-server:0.3.2
ELEPHANT_IMAGE_NAME?=elephant-server:0.3.3
ELEPHANT_NVIDIA_GID?=$$(ls -n /dev/nvidia$(ELEPHANT_GPU) | awk '{print $$4}')
ELEPHANT_DOCKER?=docker

Expand Down
4 changes: 2 additions & 2 deletions elephant-core/elephant/tests/test_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ def test_three_class_segmentation():
[-0.83362025, -1.6382282, -2.5767176, -0.9678207, -1.7188845],
[-0.91411495, -1.222617, -2.769664, -4.5017776, -0.85926974]]
]]])
torch.allclose(y, expected)
assert torch.allclose(y, expected, rtol=1e-4)


def test_three_dimensional_flow():
Expand Down Expand Up @@ -337,4 +337,4 @@ def test_three_dimensional_flow():
[-0.44132188, -0.87742317, -0.79334104, -0.7186437, -0.64516896],
[-0.42390147, -0.54549336, -0.7307426, -0.66375196, -0.2771961]]
]]])
torch.allclose(y, expected)
assert torch.allclose(y, expected, rtol=1e-4)
6 changes: 3 additions & 3 deletions elephant-core/elephant/util/tests/test_gaussian_smoothing.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def test_gaussian_smoothing_1d():
expected = np.array(
[0.68083227, 1., 1., 1., 0.68083227]).astype(np.float32)
print(test)
assert_allclose(test, expected)
assert_allclose(test, expected, rtol=1e-05, atol=1e-08)


def test_gaussian_smoothing_2d():
Expand All @@ -52,7 +52,7 @@ def test_gaussian_smoothing_2d():
[0.6808322, 1., 1., 1., 0.6808322],
[0.4635325, 0.6808322, 0.6808322, 0.6808322, 0.4635325],
]).astype(np.float32)
assert_allclose(test, expected)
assert_allclose(test, expected, rtol=1e-05, atol=1e-08)


def test_gaussian_smoothing_3d():
Expand Down Expand Up @@ -98,4 +98,4 @@ def test_gaussian_smoothing_3d():
]
).astype(np.float32)
print(test)
assert_allclose(test, expected, rtol=1e-6)
assert_allclose(test, expected, rtol=1e-05, atol=1e-08)
2 changes: 1 addition & 1 deletion elephant-core/elephant/util/tests/test_scaled_moments.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,4 @@ def test_scaled_moments_central():
expected = np.array([[16., 0., 20.],
[0., 0., 0.],
[80., 0., 100.]])
assert_allclose(mu, expected)
assert_allclose(mu, expected, rtol=1e-05, atol=1e-08)
2 changes: 1 addition & 1 deletion elephant-core/elephant/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@
# ==============================================================================
"""Version definition."""

__version__ = '0.3.2'
__version__ = '0.3.3'
2 changes: 1 addition & 1 deletion elephant.def
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Bootstrap: docker
From: pytorch/pytorch:1.4-cuda10.1-cudnn7-runtime
From: pytorch/pytorch:1.10.0-cuda11.3-cudnn8-runtime

%files
./docker /docker
Expand Down
2 changes: 1 addition & 1 deletion elephant_server.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"id": "CpJPKG_ATv39"
},
"source": [
"%env ELEPHANT_SERVER_VERSION = v0.3.2"
"%env ELEPHANT_SERVER_VERSION = v0.3.3"
],
"execution_count": null,
"outputs": []
Expand Down
Loading

0 comments on commit cfb4caa

Please sign in to comment.