Skip to content

Instantly share code, notes, and snippets.

@mdhasanai
Created September 28, 2018 04:38
Show Gist options
  • Save mdhasanai/b8d75b423b1a3f1c5c317627d1012798 to your computer and use it in GitHub Desktop.
Save mdhasanai/b8d75b423b1a3f1c5c317627d1012798 to your computer and use it in GitHub Desktop.
def relu(x):
"""
Compute the relu of x
Arguments:
x -- A scalar or numpy array of any size.
Return:
s -- relu(x)
"""
s = np.maximum(0,x)
return s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment