code: def main(
      output_dir: str,
      scene_path: str,
      name: Optional[str] = None,
      version: Optional[str] = None,
  ):
      scene_path = file_io.as_path(scene_path).expanduser()
      if name is None:
          name = scene_path.stem
          logging.info("Inferred name from scene path as %s", name)
  
      if version is None:
          n, sep, v = name.rpartition("_v")
          if sep and v and re.match("[0-9.]+", v):
              version = v
              name = n
              logging.info(
                  "Inferred version from name as %s and shortened name to %s",
                  version,
                  name,
              )
  
      logging.info("name = %s and version = %s", name, version)
      output_dir = file_io.as_path(output_dir).expanduser()
      base_dir = output_dir / name
      logging.info(
          f"Converting {scene_path} into asset source format in directory {base_dir}"
      )
      base_dir.mkdir(parents=True, exist_ok=True)
  
      logging.info(
          f"Resetting Blender and loading scene %s", scene_path
      )
      bpy.ops.wm.read_factory_settings(use_empty=True)
      bpy.ops.wm.open_mainfile(filepath=str(scene_path))
  
      manifest = {
          "name": name,
          "data_dir": str(base_dir),
          "version": version,
          "assets": {},
      }
      for obj in bpy.data.objects:
          asset_id, asset_entry = kubricify(
              obj, base_dir, asset_license="CC BY-SA 4.0"
          )
          manifest["assets"][asset_id] = asset_entry
  
      manifest_path = output_dir / (name + ".json")
      logging.info("writing manifest to '%s'", manifest_path)
      file_io.write_json(manifest, manifest_path)
  
file_path: kubric/kubric/scripts/kubasic.py
imports: import argparse
  import logging
  import os
  import re
  import sys
  import tarfile
  import tempfile
  from typing import Optional
  import bpy
  import numpy
  import pybullet
  from kubric import file_io
  from kubric.renderer import blender_utils
  from kubric.kubric_typing import PathLike
  from kubric import redirect_io
label_desc: Use image node_id 3 for calling a global function with example usage: main(output_dir, scene_path, name, version) without return types