docstr: ...Test HawkesADM4 score method
          
docstr_tok: ["...","Test","HawkesADM4","score","method"]
code: def test_hawkes_adm4_score(self):
      """...Test HawkesADM4 score method"""
      n_nodes = 2
      n_realizations = 3
  
      train_events = [
          [np.cumsum(np.random.rand(4 + i)) for i in range(n_nodes)]
          for _ in range(n_realizations)
      ]
  
      test_events = [
          [np.cumsum(np.random.rand(4 + i)) for i in range(n_nodes)]
          for _ in range(n_realizations)
      ]
  
      learner = HawkesADM4(self.decay, record_every=1)
  
      msg = "^You must either call `fit` before `score` or provide events$"
      with self.assertRaisesRegex(ValueError, msg):
          learner.score()
  
      given_baseline = np.random.rand(n_nodes)
      given_adjacency = np.random.rand(n_nodes, n_nodes)
  
      learner.fit(train_events)
  
      train_score_current_coeffs = learner.score()
      self.assertAlmostEqual(train_score_current_coeffs, 0.12029826)
  
      train_score_given_coeffs = learner.score(
          baseline=given_baseline, adjacency=given_adjacency
      )
      self.assertAlmostEqual(train_score_given_coeffs, -0.15247511)
  
      test_score_current_coeffs = learner.score(test_events)
      self.assertAlmostEqual(test_score_current_coeffs, 0.17640007)
  
      test_score_given_coeffs = learner.score(
          test_events,
          baseline=given_baseline,
          adjacency=given_adjacency,
      )
      self.assertAlmostEqual(test_score_given_coeffs, -0.07973875)
  
file_path: tick/tick/hawkes/inference/tests/hawkes_adm4_test.py
imports: import unittest
  import numpy
  from tick.hawkes import SimuHawkesExpKernels, SimuHawkesMulti
  from tick.hawkes.inference import HawkesADM4
label_desc: Use image node_id 5 for calling the Test obj's underlying member method code with example usage: obj.test_hawkes_adm4_score() without return types