code: def card(ctx):
      # We set the metadata values here so that top level arguments to --datastore and --metadata
      # Can work with the Metaflow client.
      # If we don't set the metadata here than the metaflow client picks the defaults when calling the `Task`/`Run` objects. These defaults can come from the `config.json` file or based on the `METAFLOW_PROFILE`
      from metaflow import metadata
  
      setting_metadata = "@".join(
          [ctx.obj.metadata.TYPE, ctx.obj.metadata.default_info()]
      )
      metadata(setting_metadata)
      # set the card root to the datastore according to the configuration.
      root_pth = CardDatastore.get_storage_root(
          ctx.obj.flow_datastore._storage_impl.TYPE
      )
      if root_pth is not None:
          ctx.obj.flow_datastore._storage_impl.datastore_root = root_pth
  
imports: from metaflow.client import Task
  from metaflow import JSONType, namespace
  from metaflow.util import resolve_identity
  from metaflow.exception import CommandException, MetaflowNotFound, MetaflowNamespaceMismatch
  import webbrowser
  import re
  from metaflow._vendor import click
  import os
  import json
  import uuid
  import signal
  import random
  from contextlib import contextmanager
  from functools import wraps
  from metaflow.exception import MetaflowNamespaceMismatch
  from .card_datastore import CardDatastore, NUM_SHORT_HASH_CHARS
  from .exception import CardClassFoundException, IncorrectCardArgsException, UnrenderableCardException, CardNotPresentException, TaskNotFoundException
  import traceback
  from collections import namedtuple
  from .card_resolver import resolve_paths_from_task, resumed_info
label_desc: Use image node_id 10 for calling a global function with example usage: card(ctx) without return types