{"id":23692410,"url":"https://github.com/pierridotite/cifar10-compressai","last_synced_at":"2026-02-14T16:31:09.541Z","repository":{"id":270229056,"uuid":"909689237","full_name":"pierridotite/CIFAR10-CompressAI","owner":"pierridotite","description":"Convolutional autoencoder for compressing and reconstructing CIFAR-10 images using TensorFlow.","archived":false,"fork":false,"pushed_at":"2024-12-29T14:47:30.000Z","size":180,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-12-29T15:24:46.118Z","etag":null,"topics":["ai","autoencoder","cifar10","compression","computer-vision","deep-learning","image-compression","machine-learning","neural-network","opensource","tensorflow"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pierridotite.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-29T13:49:38.000Z","updated_at":"2024-12-29T15:03:12.000Z","dependencies_parsed_at":"2024-12-29T15:37:36.412Z","dependency_job_id":null,"html_url":"https://github.com/pierridotite/CIFAR10-CompressAI","commit_stats":null,"previous_names":["pierridotite/cifar10-compressai"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pierridotite%2FCIFAR10-CompressAI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pierridotite%2FCIFAR10-CompressAI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pierridotite%2FCIFAR10-CompressAI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pierridotite%2FCIFAR10-CompressAI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pierridotite","download_url":"https://codeload.github.com/pierridotite/CIFAR10-CompressAI/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":231810382,"owners_count":18429999,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","autoencoder","cifar10","compression","computer-vision","deep-learning","image-compression","machine-learning","neural-network","opensource","tensorflow"],"created_at":"2024-12-30T03:27:35.474Z","updated_at":"2026-02-14T16:31:09.512Z","avatar_url":"https://github.com/pierridotite.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CIFAR10-CompressAI\n\n![License](https://img.shields.io/badge/license-MIT-blue.svg)\n![Python Version](https://img.shields.io/badge/python-3.8%2B-blue.svg)\n![TensorFlow Version](https://img.shields.io/badge/tensorflow-2.12.0-orange.svg)\n\n## Description\n\n**CIFAR10-CompressAI** is a project that implements a convolutional autoencoder for compressing and reconstructing images from the CIFAR-10 dataset. The autoencoder is trained using a combination of perceptual loss and Mean Squared Error (MSE) loss, providing efficient compression while preserving the quality of reconstructed images.\n\n\u003cdiv style=\"display: flex; justify-content: center;\"\u003e\n    \u003cimg src=\"models/loss_curves.png\" alt=\"Loss Curve\" width=\"300\"/\u003e\n    \u003cimg src=\"models/comparison.png\" alt=\"Compression Comparison\" width=\"300\"/\u003e\n\u003c/div\u003e\n\n## Features\n\n- **Efficient Compression**: Utilizes a convolutional autoencoder to significantly reduce the size of CIFAR-10 images.\n- **High-Quality Reconstructions**: Combines perceptual loss and MSE loss to maintain the visual quality of reconstructed images.\n- **Data Augmentation**: Implements advanced techniques to enhance the model's robustness and performance.\n- **GPU Support**: Optimized for training on GPUs using TensorFlow, accelerating the training process.\n- **Modularity**: Organized codebase with modular components, facilitating easy contributions and extensions.\n\n## Compression Metrics and Results\n\n### Compression Performance\n\n- **Original Size**: 61,440 bytes per image\n- **Compressed Size**: 5,120 bytes per image\n- **Compression Ratio**: 12.00\n\n### Explanation of Results\n\nThe **compression ratio** of **12.00** indicates that each image is compressed to one-twelfth of its original size. This substantial reduction in size demonstrates the effectiveness of the convolutional autoencoder in minimizing storage requirements without compromising the quality of the images.\n\n**Why This Model Excels:**\n\n- **Balanced Loss Functions**: By leveraging both perceptual loss and MSE loss, the model ensures that reconstructed images retain essential visual features and textures, providing a balance between compression efficiency and image fidelity.\n- **Advanced Architecture**: The convolutional layers in the autoencoder are adept at capturing spatial hierarchies and patterns in images, enabling effective compression.\n- **Data Augmentation**: Enhancing the training data with augmentation techniques makes the model more robust and improves its generalization capabilities.\n- **Optimized Training**: Utilizing GPU acceleration with TensorFlow significantly speeds up the training process, allowing for faster iterations and model improvements.\n\nOverall, **CIFAR10-CompressAI** offers a powerful solution for image compression tasks, achieving high compression ratios while maintaining the quality of the original images.\n\n## Project Structure\n\n```\nCIFAR10-CompressAI/\n├── data/                  # Folder for data\n├── models/                # Storage for trained models and images\n├── notebooks/             # Jupyter notebooks for exploration\n├── src/                   # Source code\n│   ├── data_preprocessing.py\n│   ├── models.py\n│   ├── train.py\n│   ├── evaluate.py\n├── .gitignore             # Files and folders to ignore by Git\n├── README.md              # Project documentation\n├── requirements.txt       # Project dependencies\n├── LICENSE                # Project license\n├── CONTRIBUTING.md        # Contribution guide\n```\n\n## Installation\n\n1. **Clone the Repository**\n\n    ```bash\n    git clone https://github.com/pierridotite/CIFAR10-CompressAI.git\n    cd CIFAR10-CompressAI\n    ```\n\n2. **Create a Virtual Environment (Optional but Recommended)**\n\n    ```bash\n    python -m venv venv\n    venv\\Scripts\\activate      # On Windows\n    source venv/bin/activate   # On macOS/Linux\n    ```\n\n3. **Install Dependencies**\n\n    ```bash\n    pip install -r requirements.txt\n    ```\n\n## Usage\n\n### Training the Model\n\nTo train the autoencoder, run:\n\n```bash\npython src/train.py\n```\n\n### Evaluating the Model\n\nTo evaluate and compare the original and reconstructed images, run:\n\n```bash\npython src/evaluate.py\n```\n\n## Contribution\n\nContributions are welcome! Please refer to the [CONTRIBUTING.md](CONTRIBUTING.md) file for more details.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more details.\n\n## Examples\n\n### Training\n\n![Training Example](models/loss_curves.png)\n\n### Compression Comparison\n\n![Compression Example](models/comparison.png)\n\n## Advanced Usage\n\nYou can explore the notebooks in the `notebooks/` folder for additional analyses and visualizations.\n\n---\n\nThank you for using **CIFAR10-CompressAI**! Feel free to contribute and share this project with the community.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpierridotite%2Fcifar10-compressai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpierridotite%2Fcifar10-compressai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpierridotite%2Fcifar10-compressai/lists"}