# Inputs

Before running SAW pipelines, the preparation of input files should be done first. The input files for analysis vary with the experimental procedure, the assay, and also depending on the selected SAW pipeline.

## Inputs for SAW count

Consider the following matters when preparing for input files, pipelines, and parameters:

{% hint style="success" %}
Which pipeline to use?
{% endhint %}

`SAW count` is the main pipeline to transform FASTQs (data) into spatial feature expression matrixes (information). Before starting an analysis, `SAW makeRef` should be carried out for reference index files.

{% hint style="success" %}
What is the Stereo-seq Chip?&#x20;
{% endhint %}

Stereo-seq Chip T/N, the sequencing vector, is closely linked to FASTQs. Information from the Stereo-seq Chip mainly includes **SN** (serial number) and the **chip mask** file which records CID (coordinate ID).&#x20;

{% hint style="success" %}
How to download the Stereo-seq chip mask file?
{% endhint %}

The mask file of the Stereo-seq chip is essential for `SAW count` analysis, which can be obtained from your online project files on [STOmics Cloud](https://cloud.stomics.tech/). Learn about [the tutorial](https://www.stomics.tech/helpcenter/usermanual/E.Project/D.Data.html#file-download%E2%80%94ossutil-tool-download), to download the mask file directly to your Linux clustering system.

{% hint style="success" %}
What about the selection of images?
{% endhint %}

SAW usually requires a **microscope image** (brightfield or fluorescence) to use as an anatomical map for the expression matrix. Whether or not to input an image (in TIFF or image `.tar.gz`) depends on your analysis needs.

{% hint style="success" %}
How to obtain the necessary parameters?
{% endhint %}

`--kit-version` is associated with the experimental product kit. The kit version can be found in the biochemical experiment operation manual. So that the pipeline can automatically detect the necessary parameters. For example, "Stereo-seq T FF V1.2" indicates that the analysis is conducted using a Stereo-seq Chip T with a fresh frozen tissue sample.

`--sequencing-type` is associated with the report generated by the Stereo-seq sequencing platform. For example, "PE100\_50+100" indicates 100 bp of paired-end sequencing for the product kit, where the read length of read 1 is 50 and that of read 2 is 100.

## Inputs for SAW realign

{% hint style="success" %}
Have you performed `SAW count` once?
{% endhint %}

The output `visualization.tar.gz` from `SAW count` can be input into **StereoMap** for visualization and manual processing after unpacking. Notice that the outputs of `SAW count` will play an important role in the subsequent analysis.

{% hint style="success" %}
Have you done the manual processing?
{% endhint %}

After a series of modifications, a "realigned" image `.tar.gz` file is generated from Image Processing in **StereoMap**, which should be passed back to `SAW realign`, using `--realigned-image-tar`.

***

**Access to help**

Have any questions or concerns about the inputs for your SAW run?&#x20;

Please get in touch with the **local agents** or **FAS/FBS**.
