@docfiller
def generic_laplace(input, derivative2, output=None, mode='reflect', cval=0.0, extra_arguments=(), extra_keywords=None):
 if (extra_keywords is None):
  extra_keywords = {}
 input = numpy.asarray(input)
 (output, return_value) = _ni_support._get_output(output, input)
 axes = list(range(input.ndim))
 if (len(axes) > 0):
  modes = _ni_support._normalize_sequence(mode, len(axes))
  derivative2(input, axes[0], output, modes[0], cval, *extra_arguments, **extra_keywords)
  for ii in range(1, len(axes)):
   tmp = derivative2(input, axes[ii], output.dtype, modes[ii], cval, *extra_arguments, **extra_keywords)
   output += tmp
 else:
  output[...] = input[...]
 return return_value

@ docfiller def generic_laplace ( input , derivative2 , output = None , mode = 'reflect' , cval = 0.0 , extra_arguments = ( ) , extra_keywords = None ) : if ( extra_keywords is None ) : extra_keywords = { } input = numpy . asarray ( input ) ( output , return_value ) = _ni_support . _get_output ( output , input ) axes = list ( range ( input . ndim ) ) if ( len ( axes ) > 0 ) : modes = _ni_support . _normalize_sequence ( mode , len ( axes ) ) derivative2 ( input , axes [ 0 ] , output , modes [ 0 ] , cval , * extra_arguments , ** extra_keywords ) for ii in range ( 1 , len ( axes ) ) : tmp = derivative2 ( input , axes [ ii ] , output . dtype , modes [ ii ] , cval , * extra_arguments , ** extra_keywords ) output += tmp else : output [ ... ] = input [ ... ] return return_value
n-dimensional laplace filter using a provided second derivative function parameters %s derivative2 : callable callable with the following signature:: derivative2 see extra_arguments .