Skip to content
This repository has been archived by the owner on May 31, 2023. It is now read-only.

Commit

Permalink
Fix mag selection in thumbnail generation (#136)
Browse files Browse the repository at this point in the history
  • Loading branch information
fm3 authored Aug 9, 2022
1 parent e209c9e commit fda4a0f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wkconnect/routes/datasets/thumbnail.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ async def get_thumbnail(
)
backend = request.app.ctx.backends[backend_name]
layer = [i for i in dataset.to_webknossos().dataLayers if i.name == layer_name][0]
mag: Vec3D = layer.resolutions.sort(key=lambda m: m.max_dim())[
mag: Vec3D = sorted(layer.resolutions, key=lambda m: m.max_dim())[
min(3, len(layer.resolutions) - 1)
]
center = layer.boundingBox.box().center()
Expand Down

0 comments on commit fda4a0f

Please sign in to comment.