code: def run(self, train_folder):
      # Create a datamodule from the given dataset
      datamodule = ImageClassificationData.from_folders(
          train_folder=train_folder,
          batch_size=1,
          val_split=0.5,
      )
      # Create an image classfier task with the given backbone
      model = ImageClassifier(
          datamodule.num_classes, backbone=self.backbone
      )
      # Start a Lightning trainer, with 1 training batch and 4 validation batches
      trainer = flash.Trainer(
          max_epochs=self.max_epochs,
          limit_train_batches=1,
          limit_val_batches=4,
          callbacks=[ModelCheckpoint(monitor="val_cross_entropy")],
      )
      # Train the model
      trainer.fit(model, datamodule=datamodule)
      # Save the model path
      self.best_model_path = trainer.checkpoint_callback.best_model_path
      # Save the model score
      self.best_model_score = (
          trainer.checkpoint_callback.best_model_score.item()
      )
  
file_path: pytorch-lightning/docs/source-app/code_samples/quickstart/app/app_1.py
imports: import flash
  from flash.core.data.utils import download_data
  from flash.image import ImageClassificationData, ImageClassifier
  from lightning.app import LightningWork, LightningFlow, LightningApp, CloudCompute
  from lightning.pytorch.callbacks import ModelCheckpoint
label_desc: Use image node_id 2 for calling the ImageClassifierTrainWork obj's underlying member method code with example usage: obj.run(train_folder) without return types