Skip to content

Master's thesis project consisting in the development of a pipeline to segment and render tomography data of lithium-ion batteries during abuse testing.

License

Notifications You must be signed in to change notification settings

venturellimatteo/fasttomo

Repository files navigation

fasttomo

Welcome to fasttomo, a Python package designed to address the critical task of identifying copper agglomerates in lithium-ion batteries during thermal runaway. Developed as part of my Master's thesis at ESRF (European Synchrotron Radiation Facility) from October 2023 to March 2024, fasttomo offers a powerful set of tools for analyzing and visualizing 4-dimensional CT data in $(t, z, y, x)$ format.

Key Features:

  • Load and process 4-dimensional CT data stored as NumPy arrays (.npy files).
  • Perform consistent segmentation of copper agglomerates over time.
  • Visualize data interactively, with the option to overlay segmentation masks.
  • Extract and plot various agglomerate features, such as volume, speed, and density.
  • Generate .stl mesh representations of the segmentation masks.
  • Seamlessly import .stl meshes into Blender for detailed rendering.
  • Create dynamic movies by sequencing still images.

fasttomo is a valuable tool for researchers, scientists, and engineers working on battery technology, providing insights into the behavior and characteristics of copper agglomerates in lithium-ion batteries under thermal stress.

For detailed instructions on installing, configuring, and using the package, please refer to the comprehensive documentation.

1. Installation

To install fasttomo, follow these steps:

  1. First, clone the repository to your local machine:

    git clone https://github.com/venturellimatteo/fasttomo.git
    
  2. Navigate to the project directory:

    cd fasttomo
    
  3. Create a conda virtual environment:

    conda create -n venv
    
  4. Activate the virtual environment:

    conda activate venv
    
  5. Install Python 3.8.17:

    conda install python==3.8.17
    
  6. Install requirements.txt dependencies:

    pip install -r requirements.txt

Note

Blender 3.6.4 installation is required for the usage of selected functions to render segmentation results.

2. Usage

To use fasttomo, open the python notebook file notebook.ipynb, specify the name of the experiment to process in the exp variable, optionally specify the path and initiate an instance of the Data class. From there, run any of the desired functions to segment or visualize the data.

3. Example

This example shows the code to process experiment P28A_FT_H_Exp4_2:

  1. Data class instance is initialized;
  2. Tomography data is segmented;
  3. Agglomerates features are extracted and saved as a csv file;
  4. Agglomerate data is processed and plotted;
  5. Segmentation mask is converted into stl meshes;
  6. Volumes are rendered as png files using Blender;
  7. png frames are sequenced into a movie.
import fasttomo
data = fasttomo.Data("P28A_FT_H_Exp4_2")
data.segment()
data.create_dataframe()
data.plots()
data.create_stls()
data.render()
data.create_render_movie()

4. Results

Results example

5. Documentation

For detailed documentation, including API references and usage guides, please visit the project documentation.

If you encounter any issues, have questions, or would like to suggest improvements to the documentation, please open an issue on GitHub.

6. License

This project is licensed under the MIT License - see the LICENSE.md file for details.

The MIT License is a permissive open-source license that allows you to use, modify, and distribute the code in both open-source and proprietary projects. For more details, please refer to the MIT License.

7. Acknowledgments

I would like to thank Matilda Fransson and Ludovic Broche for their invaluable guidance and support. I was fortunate to have Matilda not just as a supervisor but as a friend, with whom I shared countless laughs and precious moments. I am equally grateful to Ludo for his willingness to help and answer any question, as well as the joy his ever-present smile brought to our work.

8. Contact Information

If you have any questions, feedback, or suggestions, feel free to reach out:

You can also open an issue on GitHub or participate in discussions on my project's GitHub repository.

Feel free to connect with me on LinkedIn for more updates and collaboration opportunities.

About

Master's thesis project consisting in the development of a pipeline to segment and render tomography data of lithium-ion batteries during abuse testing.

Topics

Resources

License

Stars

Watchers

Forks