How nadigsrujan/fabfederate works
FabFederate-CNC is a local research application for estimating CNC milling-tool wear from recorded sensor data. The documented workflow prepares NASA recordings, trains centralized/local baselines and Flower federated models, evaluates held-out cases, and explains saved-model predictions. A FastAPI backend serves saved study artifacts and prediction features to a React research workspace. The graph also preserves the distinct data-preparation, federated-training, evaluation, and SHAP capabilities. Several backend paths are documented but unsampled; their internal call relationships are therefore not inferred.
Main entry points: App.tsx Application shell · study.py Study orchestration · app.py Research API · preprocessing.py Preprocessing
Components 24
Research workspace
- Application shell
frontend/src/App.tsx - Study state
frontend/src/lib/experiments.ts - Study overview
frontend/src/pages/OverviewPage.tsx - Experiment results
frontend/src/pages/ExperimentsPage.tsx - Client analysis
frontend/src/pages/ClientsPage.tsx - Dataset view
frontend/src/pages/DatasetPage.tsx - Wear estimator
frontend/src/pages/EstimatePage.tsx
Local API
- Research API
src/api/app.py
Data preparation
- Data acquisition
src/data/acquisition.py - Dataset loaders
src/data/nasa_loader.py - Preprocessing
src/data/preprocessing.py - Signal features
src/data/feature_extraction.py - Client partitioning
src/data/partitioning.py
Modeling
- Study orchestration
src/pipelines/study.py - Baseline training
src/models/train.py - Federated training
src/federated/server.py - Logical clients
src/federated/client.py - Neural model
src/models/mlp.py - Model bundles
src/models/bundle.py
Evaluation and inference
- Error metrics
src/evaluation/metrics.py - Research reports
src/evaluation/report.py - File inference
src/inference/pipeline.py - SHAP explanations
src/explainability/shap_explainer.py
Other components
- Researcher
Connections 24
- Researcher → Application shell: uses
README.md - Application shell → Study state: loads state
frontend/src/App.tsx - Application shell → Study overview: renders
frontend/src/App.tsx - Application shell → Experiment results: renders
frontend/src/App.tsx - Application shell → Client analysis: renders
frontend/src/App.tsx - Application shell → Dataset view: renders
frontend/src/App.tsx - Application shell → Wear estimator: renders
frontend/src/App.tsx - Study state → Research API: requests data
README.md - Research API → Study state: serves study
README.md - Study orchestration → Preprocessing: prepares dataset
src/pipelines/study.py - Study orchestration → Baseline training: runs baselines
src/pipelines/study.py - Study orchestration → Federated training: runs federation
src/pipelines/study.py - Study orchestration → Error metrics: evaluates predictions
src/pipelines/study.py - Study orchestration → SHAP explanations: explains predictions
src/pipelines/study.py - Federated training → Logical clients: dispatches training
src/federated/server.py - Logical clients → Neural model: trains model
src/federated/client.py - File inference → Model bundles: loads model
src/inference/pipeline.py - File inference → SHAP explanations: requests explanation
src/inference/pipeline.py - Researcher → Data acquisition: prepares recordings
README.md - Data acquisition → Dataset loaders: loads NASA data
- Preprocessing → Signal features: extracts features
- Preprocessing → Client partitioning: partitions data
- Research API → File inference: serves predictions
- Research API → Research reports: serves reports