code: def test_ModelSmoothedHinge_smoothness(self):
      np.random.seed(12)
      n_samples, n_features = 50, 2
      w0 = np.random.randn(n_features)
      c0 = np.random.randn()
      # First check with intercept
      X, y = SimuLogReg(
          w0, c0, n_samples=n_samples, verbose=False, dtype=self.dtype
      ).simulate()
  
      model = ModelSmoothedHinge(smoothness=0.123).fit(X, y)
      self.assertAlmostEqual(
          model._model.get_smoothness(), 0.123, places=3
      )
      model.smoothness = 0.765
      self.assertAlmostEqual(
          model._model.get_smoothness(), 0.765, places=3
      )
  
      msg = "^smoothness should be between 0.01 and 1$"
      with self.assertRaisesRegex(RuntimeError, msg):
          model = ModelSmoothedHinge(smoothness=-1).fit(X, y)
      with self.assertRaisesRegex(RuntimeError, msg):
          model = ModelSmoothedHinge(smoothness=1.2).fit(X, y)
      with self.assertRaisesRegex(RuntimeError, msg):
          model = ModelSmoothedHinge(smoothness=0.0).fit(X, y)
  
      with self.assertRaisesRegex(RuntimeError, msg):
          model.smoothness = 0.0
      with self.assertRaisesRegex(RuntimeError, msg):
          model.smoothness = -1.0
      with self.assertRaisesRegex(RuntimeError, msg):
          model.smoothness = 2.0
  
file_path: tick/tick/linear_model/tests/model_smoothed_hinge_test.py
imports: import unittest
  import numpy
  from scipy.sparse import csr_matrix
  from tick.linear_model import SimuLogReg, ModelSmoothedHinge
  from tick.base_model.tests.generalized_linear_model import TestGLM
label_desc: Use image node_id 2 for calling the ModelSmoothedHingeTest obj's underlying member method code with example usage: obj.test_ModelSmoothedHinge_smoothness() without return types