code: def dataset(request):
      task = request.param
      return {
          "input": torch.randn(n_instances, input_dim),
          "output": {
              "unimodal": {
                  "y_pred": torch.randn(n_instances, output_dim),
                  "y_true": torch.randint(
                      low=0, high=output_dim, size=(n_instances,)
                  )
                  if task == "classification"
                  else torch.randn(n_instances, output_dim),
              },
              "multimodal": {
                  "y_pred": [
                      torch.randn(n_instances, output_dims[0]),
                      torch.randn(n_instances, output_dims[1]),
                  ],
                  "y_true": [
                      torch.randint(
                          low=0,
                          high=output_dims[0],
                          size=(n_instances,),
                      )
                      if task == "classification"
                      else torch.randn(n_instances, output_dim),
                      torch.randint(
                          low=0,
                          high=output_dims[1],
                          size=(n_instances,),
                      )
                      if task == "classification"
                      else torch.randn(n_instances, output_dim),
                  ],
              },
          },
      }
  
imports: from typing import List
  import numpy
  import pytest
  import torch
  import torch.nn
  import torch.optim
  from torch.utils.data import DataLoader, TensorDataset
  from alibi.models.pytorch.metrics import AccuracyMetric, LossContainer
  from alibi.models.pytorch.model import Model
label_desc: Use image node_id 1 for calling a global function with example usage: dataset(request) and returns: dict