Reference PyTorch implementation of FedMARS, a credit-driven layer-wise federated learning framework.
Project description
FedMARS
FedMARS is a PyTorch implementation of Federated Mode-Aware Reliability Scoring for layer-wise trust control in heterogeneous federated learning. The method builds mode-aware layer evidence on each client, converts that evidence into a layer credit, robustly aggregates credits on the server, and uses the same credit for layer selection, server update strength, and proximal drift control.
Install
pip install .
For the matching package release:
pip install fedmars==0.5.1
Minimal use
from fedmars import FedMARS, FedMARSConfig
config = FedMARSConfig(num_rounds=40, default_budget_fraction=0.35)
trainer = FedMARS(model, config)
history = trainer.fit(clients, server_val_loader=val_loader, server_test_loader=test_loader)
Each client must be a fedmars.ClientDataset or compatible object with client_id, dataset, and optional weight fields. Datasets must return (x, y) pairs.
Implementation choices in this submission version
| Area | Submission behavior |
|---|---|
| Layer budget | Exact parameter-bit budget: selected layer bits are constrained by floor(model_bits * budget_fraction). |
| Output layer | No layer is forced by default. If no layer fits a very small budget, the selected set can be empty without violating the bit budget. |
| No-reference credit | Final credit alignment is neutral when no usable server reference exists. |
| Mixture objective | Entropy is controlled by the explicit mixture_entropy field. |
| Server momentum | EMA update: v <- m v + (1-m) delta. |
| Aggregation weighting | Positive credit weighting uses robust z-normalized client-layer credit. |
| Communication logs | Uplink, downlink, total bits, selected bits, budget bits, model bits, and budget-violation flags are recorded each round. |
The source package contains only the FedMARS architecture, data/layer utilities, and method-critical unit tests. Experiment notebooks, smoke-result CSVs, and ablation-study scripts are intentionally excluded from this submission code package.
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 fedmars-0.5.1.tar.gz.
File metadata
- Download URL: fedmars-0.5.1.tar.gz
- Upload date:
- Size: 16.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
27579fe014151a28ac819a26d1da3a249acf0dbea61cb11bfee8d75d93f46d18
|
|
| MD5 |
840cee737b5351a8bf944443c4771914
|
|
| BLAKE2b-256 |
4a4d65e8cb47f8b55f33c7da0bac00981a565a3608dbe98422eaf32557187ba7
|
File details
Details for the file fedmars-0.5.1-py3-none-any.whl.
File metadata
- Download URL: fedmars-0.5.1-py3-none-any.whl
- Upload date:
- Size: 18.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
65a63999819d0203ff5e316a52cd8addcb2e89404c46f1707c73f8f060375d1c
|
|
| MD5 |
17ceede4391006ee284e39b2263371bf
|
|
| BLAKE2b-256 |
096992fbb980ecf354e46487357c6a785c11571da00677080030b0292883e5ed
|