Skip to content

Commit 6654793

Browse files
committed
test: remove hardcoded snemi fixture path
1 parent 93f7842 commit 6654793

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

server_api/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ async def neuroglancer(req: Request):
412412
port = 4244
413413
neuroglancer.set_server_bind_address(ip, port)
414414
viewer = neuroglancer.Viewer()
415-
# SNEMI (# 3d vol dim: z,y,x)
415+
# Neuroglancer expects the EM volume axes in z, y, x order.
416416
res = neuroglancer.CoordinateSpace(
417417
names=["z", "y", "x"], units=["nm", "nm", "nm"], scales=scales
418418
)

tests/test_check_files_route.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import os
12
import pathlib
23
import unittest
34

@@ -6,7 +7,13 @@
67
from server_api.main import app as server_api_app
78

89

9-
SNEMI_ROOT = pathlib.Path("/Users/adamg/seg.bio/testing_data/snemi")
10+
REPO_ROOT = pathlib.Path(__file__).resolve().parents[1]
11+
SNEMI_ROOT = pathlib.Path(
12+
os.getenv(
13+
"PYTC_TEST_SNEMI_ROOT",
14+
REPO_ROOT.parent / "testing_data" / "snemi",
15+
)
16+
)
1017
TEST_INPUT_PATH = SNEMI_ROOT / "image" / "test-input.tif"
1118
TRAIN_LABELS_PATH = SNEMI_ROOT / "seg" / "train-labels.tif"
1219

0 commit comments

Comments
 (0)