\begin{equation}
\label{equation:weight_BCE}
\begin{gathered}
    L_i = -\left[y_i\cdot log(p(y_i)) + (1-y_i) \cdot log(1-p(y_i)) \right] \\
    L = \frac{1}{N}\sum_{i=1}^{N}L_i   \cdot (1- \frac{n_{(yi)}}{N})
    \end{gathered}
\end{equation}
