code: def test_load_state_dict_with_params_overriding_integration():
      state_dict = {"max_epochs": 100, "epoch_length": 120, "epoch": 5}
      data = range(120)
  
      # Override max_epochs
      new_max_epochs = 10
      engine = Engine(lambda e, b: 1)
      engine.load_state_dict(state_dict)
      state = engine.run(data, max_epochs=new_max_epochs)
      assert state.max_epochs == new_max_epochs
      assert (
          state.iteration == state_dict["epoch_length"] * new_max_epochs
      )
      assert state.epoch == new_max_epochs
  
      with pytest.raises(
          ValueError,
          match=r"Argument max_epochs should be greater than or equal to the start epoch",
      ):
          engine.load_state_dict(state_dict)
          engine.run(data, max_epochs=3)
  
      # Override epoch_length
      with pytest.raises(
          ValueError,
          match=r"Argument epoch_length should be same as in the state",
      ):
          engine.load_state_dict(state_dict)
          engine.run(data, epoch_length=90)
  
file_path: ignite/tests/ignite/engine/test_engine_state_dict.py
imports: from collections.abc import Mapping
  import pytest
  import torch
  from ignite.engine import Engine, Events, State
  from tests.ignite.engine import BatchChecker, EpochCounter, IterationCounter
label_desc: Use image node_id 8 for calling a global function with example usage: test_load_state_dict_with_params_overriding_integration() without return types