code: def test_warning_of_n_top_columns(
      tweet_emotion_train_test_textdata,
      tweet_emotion_train_test_probabilities,
  ):
      _, test = tweet_emotion_train_test_textdata
      _, test_probas = tweet_emotion_train_test_probabilities
      property_check = PropertySegmentsPerformance(n_top_properties=3)
      metadata_check = MetadataSegmentsPerformance(n_top_columns=2)
  
      property_warning = (
          "Parameter n_top_properties is set to 3 to avoid long computation time. This means that the "
          "check will run on 3 properties selected at random. If you want to run on all properties, set "
          "n_top_properties to None. Alternatively, you can set parameter properties to a list of the "
          "specific properties you want to run on."
      )
  
      metadata_warning = (
          "Parameter n_top_columns is set to 2 to avoid long computation time. This means that the "
          "check will run on 2 metadata columns selected at random. If you want to run on all metadata "
          "columns, set n_top_columns to None. Alternatively, you can set parameter columns to a list "
          "of the specific metadata columns you want to run on."
      )
  
      # Assert
      with pytest.warns(UserWarning, match=property_warning):
          _ = property_check.run(test, probabilities=test_probas)
      with pytest.warns(UserWarning, match=metadata_warning):
          _ = metadata_check.run(test, probabilities=test_probas)
  
file_path: deepchecks/tests/nlp/checks/model_evaluation/weak_segment_performance_test.py
imports: import numpy
  import pandas
  import pytest
  from hamcrest import assert_that, calling, close_to, equal_to, has_items, is_in, matches_regexp, raises
  from deepchecks.core.errors import DeepchecksNotSupportedError, NotEnoughSamplesError
  from deepchecks.nlp.checks import MetadataSegmentsPerformance, PropertySegmentsPerformance
  from tests.base.utils import equal_condition_result
label_desc: Use image node_id 5 for calling a global function with example usage: test_warning_of_n_top_columns(tweet_emotion_train_test_textdata, tweet_emotion_train_test_probabilities) without return types