Skip to content
Snippets Groups Projects
Commit 2f3b5b1f authored by Stephan Seitz's avatar Stephan Seitz
Browse files

Lint

parent bfc24760
No related merge requests found
Pipeline #17021 failed with stage
in 2 minutes
......@@ -100,7 +100,9 @@ def tensor_to_gpuarray(tensor):
raise ValueError(
'Cannot convert CPU tensor to GPUArray (call `cuda()` on it)')
else:
return pycuda.gpuarray.GPUArray(tensor.shape, dtype=torch_dtype_to_numpy(tensor.dtype), gpudata=tensor.data_ptr())
return pycuda.gpuarray.GPUArray(tensor.shape,
dtype=torch_dtype_to_numpy(tensor.dtype),
gpudata=tensor.data_ptr())
def gpuarray_to_tensor(gpuarray, context=None):
......
......@@ -6,7 +6,8 @@ Advantages:
- Custom Ops will be serializable
Disadavantages:
- C++ Code has to be build with correct parameters and ABI for present Tensorflow version (best integrated into Tensorflow build)
- C++ Code has to be build with correct parameters and ABI
for present Tensorflow version (best integrated into Tensorflow build)
"""
......
from lbmpy.autodiff._autodiff_lbstep import AutoDiffLatticeBoltzmannStep
from lbmpy.autodiff.adjoint_boundaryconditions import AdjointBoundaryCondition
__all__ = ['AutoDiffLatticeBoltzmannStep', 'AdjointBoundaryCondition']
......@@ -24,5 +24,3 @@ def tf_variable_from_field(field, init_val=0, constraint=None):
def tf_placeholder_from_field(field):
return tf.placeholder(dtype=field.dtype.numpy_dtype, name=field.name + '_placeholder', shape=field.shape)
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment