class_docstr: PReLU activation function.
  
  This is the elementwise function `x -> max(x, 0) + α * min(x, 0)`.
  This can be thought of as a leaky ReLU, with a learnt leak `α`.
docstr: **Arguments:**
  
  - `init_alpha`: The initial value $\alpha$ of the negative slope.
      This should either be a `float` (default value is $0.25$), or
      a JAX array of $\alpha_i$ values. The shape of such a JAX array
      should be broadcastable to the input.
docstr_tok: ["*","*","Arguments",":","*","*","-","`","init_alpha","`",":","The","initial","value","$","\\alpha","$","of","the","negative","slope",".","This","should","either","be","a","`","float","`","(","default","value","is","$","0.25","$",")",",","or","a","JAX","array","of","$","\\alpha_i","$","values",".","The","shape","of","such","a","JAX","array","should","be","broadcastable","to","the","input","."]
code: def __init__(
      self,
      init_alpha: Optional[Union[float, Array]] = 0.25,
  ):
      r"""**Arguments:**
  
      - `init_alpha`: The initial value $\alpha$ of the negative slope.
          This should either be a `float` (default value is $0.25$), or
          a JAX array of $\alpha_i$ values. The shape of such a JAX array
          should be broadcastable to the input.
      """
  
      self.negative_slope = jnp.asarray(init_alpha)
  
file_path: equinox/equinox/nn/_activations.py
imports: from typing import Optional, Union
  import jax
  import jax.numpy
  from jaxtyping import Array
  from .._module import Module
label_desc: Use image node_id 1 to create a new PReLU object from inherited base classes: Module with example: obj = PReLU(init_alpha)