{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "from_cells2stats_to_h5mu",
  "description": "Convert spatial data resulting from Aviti Teton sequencers that have been processed by the Element Biosciences cells2stats workflow to H5MU format.\n\nThis component processes cells2stats count matrices to create a standardized H5MU file for downstream analysis.\n\nThe component reads:\n- Parquet file containing the count matrix and metadata\n- Panel.json with target and batch information\n\nAnd outputs an H5MU file with:\n- Count data as the main .X matrix\n- Spatial coordinates in obsm\n- Cell Paint intensities in obsm (optional)\n- Nuclear count data as a layer (optional)\n- CellProfiler morphology metrics in obsm (optional)\n- Unassigned targets in obsm (optional)\n",
  "type": "object",
  "$defs": {
    "inputs": {
      "title": "Inputs",
      "type": "object",
      "description": "No description",
      "properties": {
        "input": {
          "type": "string",
          "format": "path",
          "exists": true,
          "description": "Path to the cells2stats output bundle",
          "help_text": "Type: `file`, multiple: `False`, required, direction: `input`, example: `\"path/to/aviti_output\"`. "
        }
      }
    },
    "outputs": {
      "title": "Outputs",
      "type": "object",
      "description": "No description",
      "properties": {
        "output": {
          "type": "string",
          "format": "path",
          "description": "Output H5MU file path.",
          "help_text": "Type: `file`, multiple: `False`, required, default: `\"$id.$key.output.h5mu\"`, direction: `output`, example: `\"output.h5mu\"`. ",
          "default": "$id.$key.output.h5mu"
        },
        "output_compression": {
          "type": "string",
          "description": "Compression format to use for the output AnnData and/or Mudata objects.\nBy default no compression is applied.\n",
          "help_text": "Type: `string`, multiple: `False`, example: `\"gzip\"`, choices: ``gzip`, `lzf``. ",
          "enum": [
            "gzip",
            "lzf"
          ]
        }
      }
    },
    "options": {
      "title": "Options",
      "type": "object",
      "description": "No description",
      "properties": {
        "modality": {
          "type": "string",
          "description": "The modality to which the processed data will be written to in the H5MU file.",
          "help_text": "Type: `string`, multiple: `False`, default: `\"rna\"`. ",
          "default": "rna"
        },
        "obsm_coordinates": {
          "type": "string",
          "description": "Key name to store the spatial coordinates (in pixels) in obsm.\nIf present, spatial coordinates in micrometers will be stored under {obsm_coordinates}_um.\nThe column names will be stored in uns.\n",
          "help_text": "Type: `string`, multiple: `False`, default: `\"spatial\"`. ",
          "default": "spatial"
        },
        "layer_nuclear_counts": {
          "type": "string",
          "description": "Name for nuclear counts layer",
          "help_text": "Type: `string`, multiple: `False`, example: `\"nuclear_counts\"`. "
        },
        "obsm_cell_paint": {
          "type": "string",
          "description": "Key name for storing Cell Paint target intensities in obsm",
          "help_text": "Type: `string`, multiple: `False`, example: `\"cell_paint\"`. "
        },
        "obsm_cell_paint_nuclear": {
          "type": "string",
          "description": "Key name for storing Nuclear Cell Paint target intensities in obsm.\nIf provided, Nuclear Cell Paint target intensity data will be stored as a separate matrix in the obsm field.\nThe column names will be stored in uns.\n",
          "help_text": "Type: `string`, multiple: `False`, example: `\"cell_paint_nuclear\"`. "
        },
        "obsm_cell_profiler": {
          "type": "string",
          "description": "Key name for storing CellProfiler morphology metrics in obsm.\nIf provided, CellProfiler morphology metrics will be stored as a separate matrix in the obsm field.\nThe column names will be stored in uns.\n",
          "help_text": "Type: `string`, multiple: `False`, example: `\"cell_profiler\"`. "
        },
        "obsm_unassigned_targets": {
          "type": "string",
          "description": "Key name for storing any unassigned target data in obsm.\nIf provided, unassigned target data will be stored as a separate matrix in the obsm field.\nThe column names will be stored in uns.\n",
          "help_text": "Type: `string`, multiple: `False`, example: `\"cell_profiler\"`. "
        }
      }
    },
    "nextflow input-output arguments": {
      "title": "Nextflow input-output arguments",
      "type": "object",
      "description": "Input/output parameters for Nextflow itself. Please note that both publishDir and publish_dir are supported but at least one has to be configured.",
      "properties": {
        "publish_dir": {
          "type": "string",
          "description": "Path to an output directory.",
          "help_text": "Type: `string`, multiple: `False`, required, example: `\"output/\"`. "
        }
      }
    }
  },
  "allOf": [
    {
      "$ref": "#/$defs/inputs"
    },
    {
      "$ref": "#/$defs/outputs"
    },
    {
      "$ref": "#/$defs/options"
    },
    {
      "$ref": "#/$defs/nextflow input-output arguments"
    }
  ]
}
