code: def _lightly_cli(cfg, is_cli_call=True):
      cfg["loader"]["shuffle"] = True
      cfg["loader"]["drop_last"] = True
  
      if cfg["trainer"]["max_epochs"] > 0:
          print("#" * 10 + " Starting to train an embedding model.")
          checkpoint = _train_cli(cfg, is_cli_call)
      else:
          checkpoint = ""
  
      cfg["loader"]["shuffle"] = False
      cfg["loader"]["drop_last"] = False
      cfg["checkpoint"] = checkpoint
  
      print("#" * 10 + " Starting to embed your dataset.")
      embeddings = _embed_cli(cfg, is_cli_call)
      cfg["embeddings"] = embeddings
  
      print("#" * 10 + " Finished")
  
file_path: lightly/lightly/cli/lightly_cli.py
imports: import hydra
  from omegaconf import DictConfig
  from lightly.cli._helpers import fix_hydra_arguments
  from lightly.cli.embed_cli import _embed_cli
  from lightly.cli.train_cli import _train_cli
  from lightly.utils.hipify import print_as_warning
label_desc: Use image node_id 1 for calling a global function with example usage: _lightly_cli(cfg, is_cli_call) without return types