code: def test_vision_data_n_of_samples_per_class_inference_for_classification_dataset(
      mnist_visiondata_train,
  ):
      # Act
      run_update_loop(mnist_visiondata_train)
  
      # Assert
      assert_that(
          mnist_visiondata_train.number_of_images_cached, equal_to(200)
      )
      assert_that(
          sorted(mnist_visiondata_train.get_observed_classes()),
          equal_to([str(x) for x in range(10)]),
      )
  
imports: import numpy
  import pytest
  import torch
  from hamcrest import assert_that, calling, equal_to, has_length, is_not, raises
  from torch.utils.data import DataLoader
  from deepchecks.core.errors import DatasetValidationError, ValidationError
  from deepchecks.vision.datasets.classification.mnist_torch import IterableTorchMnistDataset, collate_without_model
  from deepchecks.vision.datasets.detection import coco_torch
  from deepchecks.vision.datasets.segmentation import segmentation_coco
  from deepchecks.vision.utils.test_utils import replace_collate_fn_dataloader
  from deepchecks.vision.vision_data import TaskType, VisionData
  from deepchecks.vision.vision_data.utils import validate_vision_data_compatibility
  from tests.vision.conftest import run_update_loop
label_desc: Use image node_id 7 for calling a global function with example usage: test_vision_data_n_of_samples_per_class_inference_for_classification_dataset(mnist_visiondata_train) without return types