code: def net_fit(self, net, data):
      # Careful, don't call additional fits on this, since that would have
      # side effects on other tests.
      X, y = data
      return net.fit(X, y)
  
imports: from unittest.mock import Mock
  import numpy
  import pytest
  import torch
  from scipy.special import expit
  from sklearn.base import clone
  from torch import nn
  from skorch.tests.conftest import INFERENCE_METHODS
label_desc: Use image node_id 6 for calling the TestNeuralNet obj's underlying member method code with example usage: obj.net_fit(net, data) and returns: net