<jupyter_start><jupyter_text>Implementing sigmoid function<jupyter_code>def sigmoid(x):
    return 1/(1+math.exp(-x))
sigmoid(10)
sigmoid(-10)<jupyter_output><empty_output><jupyter_text>Implementing tanh<jupyter_code>def tanh(x):
    return ((math.exp(x) - math.exp(-x))/(math.exp(x) + math.exp(-x)))
tanh(10)
tanh(-10)<jupyter_output><empty_output><jupyter_text>Implementing ReLU<jupyter_code>def ReLU(x):
    return max(0,x)
ReLU(10)
ReLU(-10)<jupyter_output><empty_output><jupyter_text>Implementing Leaky ReLU<jupyter_code>def LeakyReLU(x):
    return max(0.1*x, x)
LeakyReLU(10)
LeakyReLU(-10)<jupyter_output><empty_output>
StarcoderdataJupyterStructuredCleanDedup