Implement the forward pass of a 1D batch normalization layer that uses Bessel's correction (the unbiased variance estimator, dividing by N - 1 instead of N) when computing the per-feature variance.
Given:
X: input batch, numpy array of shape (N, D) where N is the batch size and D is the number of features.gamma: learnable scale (gain), numpy array of shape (D,).beta: learnable shift (bias), numpy array of shape (D,).eps: small float added inside the square root for numerical stability.Compute, for each feature column independently:
N in the denominator).N - 1 in the denominator -- Bessel's correction).x_hat = (X - mean) / sqrt(var + eps).y = gamma * x_hat + beta.Return the output y as a numpy array of shape (N, D).
Assume N >= 2. Do not round inside the solution; the test cases handle any rounding.