From ce5708a6d30757c30029562116d3538dd1aaf81a Mon Sep 17 00:00:00 2001 From: AlainKadar Date: Wed, 14 Feb 2024 09:32:29 -0500 Subject: [PATCH] Allow any surface for 2D --- StructuralGT/util.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/StructuralGT/util.py b/StructuralGT/util.py index 784b1df..212dc68 100644 --- a/StructuralGT/util.py +++ b/StructuralGT/util.py @@ -138,7 +138,9 @@ class _cropper: def __init__(self, Network, domain=None): self.dim = Network.dim - if domain is None or Network._2d: + if Network._2d: + self.surface = 0 + elif domain is None: self.surface = int( _fname(Network.dir + '/' + Network.image_stack[0][1]).num ) # Strip file type and 'slice' then convert to int