brainpy.tools.errors.check_error_in_jit#

brainpy.tools.errors.check_error_in_jit(pred, err_fun, err_arg=None)[source]#

Check errors in a jit function.

Parameters
  • pred (bool) – The boolean prediction.

  • err_fun (callable) – The error function, which raise errors.

  • err_arg (any) – The arguments which passed into err_f.