Federated Learning for Metaverse Infrastructures with MARL, Privacy, and Sustainability
Project description
MetaFed-FL: Federated Learning for Metaverse Systems
๐ฌ Research Overview
MetaFed is a cutting-edge federated learning (FL) framework specifically designed for Metaverse infrastructures. This research addresses the critical challenges of privacy, performance, and sustainability in distributed AI systems.
Paper: MetaFed: Advancing Privacy, Performance, and Sustainability in Federated Metaverse Systems
Authors: Muhammet Anil Yagiz, Zeynep Sude Cengiz, Polat Goktas (2025)
๐ Visit Project Website - Interactive demos, tutorials, and detailed documentation
๐ ๏ธ Installation
Prerequisites
- Python 3.9+
- PyTorch 2.2.2+
- CUDA (optional, for GPU acceleration)
Dependencies
# Core dependencies
pip install torch>=2.2.2 torchvision>=0.17.2
pip install numpy>=1.26.4 pandas>=2.2.2
pip install matplotlib>=3.9.2 timm>=1.0.8
# Development dependencies
pip install -r requirements-dev.txt
Package Installation
# Install as editable package
pip install -e .
# Or install from PyPI (when available)
pip install metafed-fl
๐ Quick Start
# Clone the repository
git clone https://github.com/afrilab/MetaFed-FL.git
cd MetaFed-FL
# Install dependencies
pip install -r requirements.txt
# Run MNIST experiment
python -m experiments.mnist.run_experiment
# Run CIFAR-10 experiment
python -m experiments.cifar10.run_experiment
๐ Key Features
๐ค Multi-Agent Reinforcement Learning (MARL)
- Dynamic client orchestration and selection
- Adaptive resource allocation
- Intelligent scheduling algorithms
๐ Privacy-Preserving Techniques
- Homomorphic encryption for secure aggregation
- Differential privacy for data protection
- Zero-knowledge proof mechanisms
๐ฑ Carbon-Aware Scheduling
- Real-time carbon intensity tracking
- Renewable energy-aligned orchestration
- Sustainable resource management
๐ Comprehensive Benchmarks
- MNIST with ResNet-18 architecture
- CIFAR-10 with ResNet-18 architecture
- Multiple federated learning algorithms
- Extensive performance metrics
๐ Performance Metrics
| Dataset | Algorithm | Accuracy Improvement | CO2 Reduction | Efficiency Gain |
|---|---|---|---|---|
| MNIST | FedAvg+MARL | +15% | -35% | +20% |
| CIFAR-10 | FedProx+MARL | +20% | -45% | +25% |
| CIFAR-10 | SCAFFOLD+MARL | +18% | -40% | +22% |
Compared to baseline federated learning algorithms
๐ Project Structure
MetaFed-FL/
โโโ src/metafed/ # Core package
โ โโโ core/ # FL core components
โ โโโ algorithms/ # FL algorithms
โ โโโ orchestration/ # MARL orchestration
โ โโโ privacy/ # Privacy mechanisms
โ โโโ green/ # Carbon-aware features
โ โโโ utils/ # Utilities
โโโ experiments/ # Experiment runners
โ โโโ mnist/ # MNIST experiments
โ โโโ cifar10/ # CIFAR-10 experiments
โโโ tests/ # Test suite
โโโ docs/ # Documentation
โโโ scripts/ # Utility scripts
๐งช Running Experiments
Command Line Interface
# MNIST with FedAvg + MARL
metafed-mnist --algorithm fedavg --orchestrator rl --rounds 100
# CIFAR-10 with privacy preservation
metafed-cifar10 --algorithm fedprox --privacy differential --epsilon 1.0
# Green-aware scheduling
metafed-mnist --green-aware --carbon-tracking
Configuration Files
# Using YAML configuration
python -m experiments.mnist.run_experiment --config configs/fedavg_privacy.yaml
Jupyter Notebooks (Legacy)
# For research and exploration
jupyter notebook experiments/notebooks/
๐ง Advanced Configuration
Algorithm Selection
- FedAvg: Standard federated averaging
- FedProx: Proximal federated optimization
- SCAFFOLD: Stochastic controlled averaging
Orchestration Methods
- Random: Random client selection
- RL-based: Multi-agent reinforcement learning
- Green-aware: Carbon-optimized selection
Privacy Settings
- Homomorphic Encryption: Secure aggregation
- Differential Privacy: ฮต-differential privacy
- Hybrid: Combined privacy mechanisms
๐ค Contributing
We welcome contributions! Please see our Contributing Guide for details.
Development Setup
# Clone and setup development environment
git clone https://github.com/afrilab/MetaFed-FL.git
cd MetaFed-FL
pip install -e ".[dev]"
# Run tests
pytest tests/
# Run linting
flake8 src/ tests/
black src/ tests/
Code Style
- Black for code formatting
- Flake8 for linting
- isort for import sorting
- Type hints for better code documentation
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ Citation
If you use MetaFed-FL in your research, please cite:
@misc{yagiz2025metafedadvancingprivacyperformance,
title={MetaFed: Advancing Privacy, Performance, and Sustainability in Federated Metaverse Systems},
author={Muhammet Anil Yagiz and Zeynep Sude Cengiz and Polat Goktas},
year={2025},
eprint={2508.17341},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/2508.17341}
}
๐ Acknowledgments
- AFRI Lab for supporting this research
- PyTorch Team for the excellent deep learning framework
- Federated Learning Community for inspiration and collaboration
Built with โค๏ธ for the Federated Learning Community
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file metafed_fl-1.0.0.tar.gz.
File metadata
- Download URL: metafed_fl-1.0.0.tar.gz
- Upload date:
- Size: 55.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ff37b92fdc8f9a4a0682b10bf54e1d826203d2c924f0af916a363bce07a6114e
|
|
| MD5 |
0d69af46c2f1794df3c1a4bd24631cb6
|
|
| BLAKE2b-256 |
231dc641ad9fb69296ff6be687f95b0d962df812ba7fae8d8f1667bca1d4ae50
|
File details
Details for the file metafed_fl-1.0.0-py3-none-any.whl.
File metadata
- Download URL: metafed_fl-1.0.0-py3-none-any.whl
- Upload date:
- Size: 47.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b7b936fcb424ff065531e40ef8561973a2ebefaef40570fe7a0367cdaa94f401
|
|
| MD5 |
671eefeeae4b06dde2db86ffdd20301c
|
|
| BLAKE2b-256 |
64ef2ec98fd354408a05c67851819aa9810ce69db65d347da5fbfef7825ca057
|