code: def test_mismatched_dimensions_raise_configuration_errors(self):
      params = Params.from_file(self.param_file)
      # Make the input_dim to the first feedforward_layer wrong - it should be 2.
      params["model"]["attend_feedforward"]["input_dim"] = 10
      with pytest.raises(ConfigurationError):
          Model.from_params(
              vocab=self.vocab, params=params.pop("model")
          )
  
      params = Params.from_file(self.param_file)
      # Make the projection output_dim of the last layer wrong - it should be
      # 3, equal to the number of classes.
      params["model"]["aggregate_feedforward"]["output_dim"] = 10
      with pytest.raises(ConfigurationError):
          Model.from_params(
              vocab=self.vocab, params=params.pop("model")
          )
  
file_path: magnitude/pymagnitude/third_party/allennlp/tests/models/decomposable_attention_test.py
imports: from __future__ import with_statement
  from __future__ import division
  from __future__ import absolute_import
  from flaky import flaky
  import pytest
  import numpy
  from numpy.testing import assert_almost_equal
  from allennlp.common import Params
  from allennlp.common.checks import ConfigurationError
  from allennlp.common.testing import ModelTestCase
  from allennlp.models import DecomposableAttention, Model
label_desc: Use image node_id 6 for calling the TestDecomposableAttention obj's underlying member method code with example usage: obj.test_mismatched_dimensions_raise_configuration_errors() without return types