Skip to content

Commit

Permalink
try octree coordinates in nm
Browse files Browse the repository at this point in the history
  • Loading branch information
akhileshh committed Jan 1, 2025
1 parent cc158ac commit 66190e6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pychunkedgraph/meshing/manifest/multiscale.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from ..meshgen_utils import get_json_info


def _get_hierarchy(cg: ChunkedGraph, node_id: NODE_ID) -> Dict:
def _get_hierarchy(cg: ChunkedGraph, node_id: np.uint64) -> Dict:
node_children = {}
layer = cg.get_chunk_layer(node_id)
if layer < 2:
Expand Down Expand Up @@ -104,7 +104,7 @@ def less_msb(x: int, y: int) -> bool:


def build_octree(
cg: ChunkedGraph, node_id: NODE_ID, node_children: Dict, mesh_fragments: Dict
cg: ChunkedGraph, node_id: np.uint64, node_children: Dict, mesh_fragments: Dict
):
"""
From neuroglancer multiscale specification:
Expand Down Expand Up @@ -140,7 +140,7 @@ def build_octree(
children = node_children[current_node]
node_coords = node_coords_d[current_node]

x, y, z = node_coords
x, y, z = node_coords * cg.meta.resolution
offset = OCTREE_NODE_SIZE * row_counter
octree[offset + 0] = x
octree[offset + 1] = y
Expand Down Expand Up @@ -170,7 +170,7 @@ def build_octree(
return octree, octree_node_ids, octree_fragments


def get_manifest(cg: ChunkedGraph, node_id: NODE_ID) -> Dict:
def get_manifest(cg: ChunkedGraph, node_id: np.uint64) -> Dict:
node_children = _get_hierarchy(cg, node_id)
node_ids = np.fromiter(node_children.keys(), dtype=NODE_ID)
manifest_cache = ManifestCache(cg.graph_id, initial=True)
Expand Down

0 comments on commit 66190e6

Please sign in to comment.