CaliAli Parameters Overview
This table lists all CaliAli parameters, their default values, a brief description, and guidance on how to choose them.
π Parameter Table
πΉ General Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
gSig |
2.5 |
Neuron filter size in pixels |
Use 1/5 of the neuron diameter in pixels. If unsure, opt for smaller values. |
sf |
10 |
Frame rate (fps) |
Set to match the acquisition frame rate. |
input_files |
[] |
Paths to input video files |
Leave empty to manually select files. |
output_files |
[] |
Paths to output video files |
Leave empty for default naming (recommended). |
πΉ Downsampling Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
BVsize |
[] |
Size of blood vessels in pixels [min, max] |
Leave empty to automatically calculate based on gSig or use BV_app for optimal selection. |
spatial_ds |
1 |
Spatial downsampling factor |
Increase for faster processing, decrease for higher resolution. |
temporal_ds |
1 |
Temporal downsampling factor |
Increase only if memory constraints prevent full processing. |
file_extension |
'avi' |
File extension for processed videos organized in folders |
Used when sessions are split into multiple files. |
πΉ Preprocessing Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
neuron_enhance |
true |
Use MIN1PIE background subtraction |
Keep enabled unless signal loss is observed during preprocessing. |
noise_scale |
true |
Enable noise scaling per pixel |
Keep enabled unless signal loss is observed during preprocessing. |
detrend |
1 |
Detrending window (seconds), 0 = no detrending |
Set to the duration of calcium transients in seconds. |
πΉ Motion Correction Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
reference_projection_rigid |
'BV' |
Reference projection for rigid correction |
Choose neuron if blood vessels are not suitable. |
do_non_rigid |
false |
Perform non-rigid motion correction |
Enable only after confirming rigid correction was insufficient. |
non_rigid_pyramid |
{'BV','BV','neuron'} |
Multi-level registration pyramid for non-rigid correction |
Use default unless BV is unavailable. |
non_rigid_batch_size |
[20,60] |
Batch size range for non-rigid correction, CaliAli will optimize within this range. |
Set as [2 x sf, 6 x sf] . |
πΉ Inter-Session Alignment Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
do_alignment |
true |
Perform inter-session alignment |
Always true unless sessions were pre-aligned. If false, videos will be concatenated without registration. |
projections |
'BV+neuron' |
Projection method used for alignment |
By default, use both blood vessels and neurons for registration. If one is unsuitable, choose either BV or neurons. |
final_neurons |
false |
Use an additional alignment iteration based on neurons |
Enable if session registration was inaccurate. Often not necessary |
Force_BV |
0 |
Force BV alignment even if stability score is low |
Sometimes BV stability score may be low as results of a debris in the FOV. Setting this parameter to true would ensure that BV are used for registration |
π CNMF-E Parameters Overview
πΉ Memory and Patch Processing Parameters
πΉ Initialization Parameters
πΉ Spatial Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
with_dendrites |
true |
Do not assume that signals are circular during extraction |
Always enable for better CNMF convergence and proper dendrite detection. |
spatial_constraints |
{'connected': False, 'circular': False} |
Constraints for spatial filtering |
[Always disable for better CNMF convergence and dendrite identification.] |
spatial_algorithm |
'hals_thresh' |
Algorithm for spatial extraction |
Use default unless alternative extraction methods are needed. |
πΉ Temporal Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
deconv_flag |
true |
Enable deconvolution |
Use default if unsure. Enable for better temporal resolution. |
deconv_options |
{'type': 'ar1', 'method': 'foopsi', 'smin': -5, 'optimize_pars': True, 'max_tau': 100} |
Deconvolution settings |
Use default parameters to minimize false-positives and computational stability |
πΉ Merging Parameters
Parameter Name |
Default Value |
Description |
How to Choose |
merge_thr_spatial |
[0.8, 0.4, -inf] |
Merge components with highly correlated spatial shapes (corr=0.8 ), moderate temporal correlations of calcium activities (corr=0.4 ), and disregard spikes correlations (corr=-inf ). |
Increase spatial correlation threshold for stricter merging. |