def _safe_compute_error(X, W, H):
    if not sp.issparse(X):
        error = norm(X - np.dot(W, H))
    else:
        norm_X = np.dot(X.data, X.data)
        norm_WH = trace_dot(np.dot(np.dot(W.T, W), H), H)
        cross_prod = trace_dot((X * H.T), W)
        error = sqrt(norm_X + norm_WH - 2. * cross_prod)
    return error
I don't want environment vars to be provided as
dataset/ETHPy150Open scikit-learn/scikit-learn/sklearn/decomposition/nmf.py/_safe_compute_error--crossover with--dataset/ETHPy150Open j-bennet/wharfee/wharfee/options.py/OptParser.assert_option_format