4

What does the / sign means in the signature of numpy functions? The / sign appears between the positional and keword arguments.

For example:

sqrt(x, /, out=None, *, where=True, casting='same_kind', order='K', dtype=None, subok=True[, signature, extobj])
power(x1, x2, /, out=None, *, where=True, casting='same_kind', order='K', dtype=None, subok=True[, signature, extobj])

Online documentation of numpy.sqrt -- and numpy.power functions.

Eric Duminil
  • 52,989
  • 9
  • 71
  • 124

0 Answers0