add build to pyd

This commit is contained in:
bluepulsar
2026-01-04 17:30:22 +08:00
parent 07efe0ff81
commit 3d805c69db
5 changed files with 911 additions and 5 deletions
+2
View File
@@ -284,6 +284,8 @@ class UnstructuredGrid(object):
self.nsimplices = self.simplices.shape[0]
if self.dim != self.simplices.shape[1]-1:
pdim = self.dim
sdim = self.simplices.shape[1]-1
raise SyntaxError("Dimension mismatch! pdim = "+str(pdim)+" and sdim = "+str(sdim)+" do not match!")
self.adjacent_faces = []
+3 -2
View File
@@ -296,7 +296,7 @@ class PoissonSolver(object):
def solve(self, f, verbose=False):
if not self.ready:
init(verbose)
self.prepare(verbose)
fshape = f.shape
@@ -506,7 +506,8 @@ class PoissonSolver(object):
print(' - GPU solver not optimized for unstructured points, using CPU')
return [self.solve(f, verbose) for f in f_list]
return results
# If we reach here, it's an unsupported case
raise ValueError(f"Unsupported point type '{self.ptype}' for GPU batch solver")
def clear_gpu_cache(self):
"""Clear GPU cache to free GPU memory"""