Skip to content
Snippets Groups Projects
Commit 6741a3fd authored by Chichi Lalescu's avatar Chichi Lalescu
Browse files

try to fix initialization for noncubic grids

parent 9dc6cfc5
No related branches found
No related tags found
1 merge request!23WIP: Feature/use cmake
Pipeline #
...@@ -203,10 +203,11 @@ def padd_with_zeros( ...@@ -203,10 +203,11 @@ def padd_with_zeros(
""" """
if (type(odtype) == type(None)): if (type(odtype) == type(None)):
odtype = a.dtype odtype = a.dtype
assert(a.shape[0] <= n0 and print(a.shape, n0, n1, n2//2+1)
a.shape[1] <= n1 and assert(a.shape[0] <= n1 and
a.shape[1] <= n0 and
a.shape[2] <= n2//2+1) a.shape[2] <= n2//2+1)
b = np.zeros((n0, n1, n2//2 + 1) + a.shape[3:], dtype = odtype) b = np.zeros((n1, n0, n2//2 + 1) + a.shape[3:], dtype = odtype)
m0 = a.shape[1] m0 = a.shape[1]
m1 = a.shape[0] m1 = a.shape[0]
m2 = a.shape[2] m2 = a.shape[2]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment