Metadata-Version: 2.4
Name: theatrics
Version: 1.1.3
Summary: GUI for RICS and SFCS analysis
Author-email: Yusuf Qutbuddin <yusuf.qutbuddin@gmail.com>
License: BSD 3-Clause License
        
        Copyright (c) 2025, Yusuf Qutbuddin
        
        Redistribution and use in source and binary forms, with or without
        modification, are permitted provided that the following conditions are met:
        
        1. Redistributions of source code must retain the above copyright notice, this
           list of conditions and the following disclaimer.
        
        2. Redistributions in binary form must reproduce the above copyright notice,
           this list of conditions and the following disclaimer in the documentation
           and/or other materials provided with the distribution.
        
        3. Neither the name of the copyright holder nor the names of its
           contributors may be used to endorse or promote products derived from
           this software without specific prior written permission.
        
        THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
        AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
        IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
        DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
        FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
        DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
        SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
        CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
        OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
        OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy
Requires-Dist: scipy
Requires-Dist: matplotlib
Requires-Dist: pandas
Requires-Dist: tifffile
Requires-Dist: tqdm
Requires-Dist: multipletau
Requires-Dist: sv-ttk
Requires-Dist: pylibCZIrw
Requires-Dist: scikit-image
Requires-Dist: lmfit
Dynamic: license-file

The software is being actively developed and currently has basic functionalities available, in case of any issues please contact yusufqq@biochem.mpg.de.

# Raster Image Correlation Spectroscopy simulation and analysis
A modular, extensible graphical user interface for performing and analyzing Raster Image Correlation Spectroscopy (RICS) experiments. This toolkit supports simulation, data import/export, and advanced analysis with a user-friendly workflow designed for membrane biophysics, imaging, and fluorescence correlation studies.
Currently the software is limited to Zeiss (.czi) files and TIFF files for the input image format for the raster scanned image. There will be a future update to involve other commonly used file types from other commercial microscope companies. 
## Features
**Flexible RICS simulations**: Isotropic, anisotropic, and rotated diffusion models.

**Analysis**: Fit and analyze real or simulated image stacks. (Non-GUI batch analysis)

**Progress monitoring**: Responsive GUI with real-time progress and status bars.

**Modular design**: Easily extend with new simulation, import, or analysis modules.

**Visualization**: Integrated with Matplotlib for RICS map display and fitting results.

## Installation

The current version has been tested to work through a conda environment with some necessary modules, you can also download anaconda [here](https://www.anaconda.com/). You can use the environment.yaml file for setting up the environment. 

**For Windows**: `conda env create --name <ENVNAME> --file environment_win.yml`

**For Linux**: `conda env create --name <ENVNAME> --file environment_lin.yml`

 The software hasn't been tested for Mac but there is no particular reason why it shouldn't work. Once this test has been done, the environment file for Mac will also be uploaded. 

 ## Use

 Follow the simple steps to use the GUI. 

 1. Activate the environment: `conda activate <ENVNAME>`
 2. Go to the correct installation directory and run `python theatRICS_gui.py`

 This should launch the GUI with the following tabs loaded. 

**1. Simulation tab**

 The simulation tab contains the necessary parameters to use for simulating a raster scanned image for particles diffusing in 2D. 
 
 ![Simulation tab](/screenshots/Simulation_tab.png)

 The simulation can be run for isotropic and anisotropic diffusion. For isotropic case, choose the same diffusion coefficient for x and y. 

 
**2. RICS export tab**

 The window size is necessary for moving average correction, and **must** be an odd number. 
 
 ![Export tab](/screenshots/Export_tab.png)

**3. RICS fitting tab**

 The fitting tab requires information of the PSF and the imaging parameters (these parameters can also be provided by uploading a czi file directly). 
 
 ![Fitting tab](/screenshots/Fitting_tab.png)


**4. Results and log tab**

 This is where the results and logging takes place. 

 ## Contributions and Authors

 The majority of the code and functionality is developed by Yusuf Qutbuddin (yusufqq@biochem.mpg.de) and the code and the method is inspired and follows similar algorithms as the [PAM](https://gitlab.com/PAM-PIE/PAM.git) software. Some functionalities have been derived from an earlier script by Jan-Hagen Krohn. Perplexity.ai has been used for debugging, annotation and file parsing algorithms and for searching and implementing tkinter. 
