diff --git a/examples/advanced-pytorch/pyproject.toml b/examples/advanced-pytorch/pyproject.toml index 11352d36b28c..9190a288612e 100644 --- a/examples/advanced-pytorch/pyproject.toml +++ b/examples/advanced-pytorch/pyproject.toml @@ -9,9 +9,9 @@ description = "Federated Learning with PyTorch and Flower (Advanced Example)" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", "wandb==0.17.8", ] diff --git a/examples/advanced-tensorflow/pyproject.toml b/examples/advanced-tensorflow/pyproject.toml index 869e8239093b..13432ce95186 100644 --- a/examples/advanced-tensorflow/pyproject.toml +++ b/examples/advanced-tensorflow/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Learning with Tensorflow/Keras and Flower (Advanced Exa license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "tensorflow-cpu>=2.9.1, != 2.11.1 ; platform_machine == \"x86_64\"", "tensorflow-macos>=2.9.1, != 2.11.1 ; sys_platform == \"darwin\" and platform_machine == \"arm64\"", "wandb==0.17.8", diff --git a/examples/custom-metrics/pyproject.toml b/examples/custom-metrics/pyproject.toml index 1068ccbc1977..fb67b185aa46 100644 --- a/examples/custom-metrics/pyproject.toml +++ b/examples/custom-metrics/pyproject.toml @@ -13,10 +13,10 @@ description = "Federated Learning with Flower and Custom Metrics" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "scikit-learn>=1.2.2", - "tensorflow==2.12.1; sys_platform != 'darwin'", - "tensorflow-macos==2.12.0; sys_platform == 'darwin'", + "flwr-datasets[vision]>=0.5.0", + "scikit-learn>=1.6.0", + "tensorflow>=2.12.1; (platform_machine == \"x86_64\" or platform_machine == \"aarch64\")", + "tensorflow-macos>=2.12.1; sys_platform == \"darwin\" and platform_machine == \"arm64\"", ] [tool.hatch.build.targets.wheel] diff --git a/examples/embedded-devices/embeddedexample/task.py b/examples/embedded-devices/embeddedexample/task.py index f08441c0426a..6f89a551ee19 100644 --- a/examples/embedded-devices/embeddedexample/task.py +++ b/examples/embedded-devices/embeddedexample/task.py @@ -84,6 +84,8 @@ def train(net, trainloader, valloader, epochs, learning_rate, device): def test(net, testloader, device): """Validate the model on the test set.""" + net.to(device) # move model to GPU if available + net.eval() criterion = torch.nn.CrossEntropyLoss() correct, loss = 0, 0.0 with torch.no_grad(): diff --git a/examples/embedded-devices/pyproject.toml b/examples/embedded-devices/pyproject.toml index 859cda796b1d..fb37a17dd36c 100644 --- a/examples/embedded-devices/pyproject.toml +++ b/examples/embedded-devices/pyproject.toml @@ -8,10 +8,10 @@ version = "1.0.0" description = "Federated AI with Embedded Devices using Flower" license = "Apache-2.0" dependencies = [ - "flwr>=1.14.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr>=1.15.0", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build] @@ -41,5 +41,5 @@ batch-size = 32 default = "embedded-federation" [tool.flwr.federations.embedded-federation] -address = "49.12.200.204:9093" +address = "127.0.0.1:9093" insecure = true diff --git a/examples/federated-kaplan-meier-fitter/pyproject.toml b/examples/federated-kaplan-meier-fitter/pyproject.toml index 6a1344173a1c..ba0d7d758d63 100644 --- a/examples/federated-kaplan-meier-fitter/pyproject.toml +++ b/examples/federated-kaplan-meier-fitter/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Kaplan Meier Fitter with Flower" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets>=0.3.0", + "flwr-datasets>=0.5.0", "numpy>=1.23.2", "pandas>=2.0.0", "lifelines>=0.28.0", diff --git a/examples/fl-dp-sa/pyproject.toml b/examples/fl-dp-sa/pyproject.toml index b0d52500cb88..c547abc3cce8 100644 --- a/examples/fl-dp-sa/pyproject.toml +++ b/examples/fl-dp-sa/pyproject.toml @@ -9,9 +9,9 @@ description = "Central Differential Privacy and Secure Aggregation in Flower" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/fl-tabular/pyproject.toml b/examples/fl-tabular/pyproject.toml index f12fe06b5a8d..77ebe9a63658 100644 --- a/examples/fl-tabular/pyproject.toml +++ b/examples/fl-tabular/pyproject.toml @@ -9,9 +9,9 @@ description = "Adult Census Income Tabular Dataset and Federated Learning in Flo license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets>=0.3.0", + "flwr-datasets>=0.5.0", "torch==2.5.1", - "scikit-learn==1.5.0", + "scikit-learn==1.6.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/flower-authentication/pyproject.toml b/examples/flower-authentication/pyproject.toml index 2b3bbed5c2cf..35801fb95fc2 100644 --- a/examples/flower-authentication/pyproject.toml +++ b/examples/flower-authentication/pyproject.toml @@ -8,8 +8,8 @@ version = "1.0.0" description = "Federated Learning with PyTorch and authenticated Flower " license = "Apache-2.0" dependencies = [ - "flwr>=1.14.0", - "flwr-datasets[vision]>=0.4.0", + "flwr>=1.15.0", + "flwr-datasets[vision]>=0.5.0", "torch>=2.5.0,<3.0.0", "torchvision>=0.20.1,<0.21.0", ] diff --git a/examples/flower-secure-aggregation/pyproject.toml b/examples/flower-secure-aggregation/pyproject.toml index b974c6110c43..5e5908a6fea9 100644 --- a/examples/flower-secure-aggregation/pyproject.toml +++ b/examples/flower-secure-aggregation/pyproject.toml @@ -9,9 +9,9 @@ description = "Secure Aggregation in Flower" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/flower-simulation-step-by-step-pytorch/my-awesome-app/pyproject.toml b/examples/flower-simulation-step-by-step-pytorch/my-awesome-app/pyproject.toml index 1b81097edf33..ba3ff09ec333 100644 --- a/examples/flower-simulation-step-by-step-pytorch/my-awesome-app/pyproject.toml +++ b/examples/flower-simulation-step-by-step-pytorch/my-awesome-app/pyproject.toml @@ -8,10 +8,10 @@ version = "1.0.0" description = "" license = "Apache-2.0" dependencies = [ - "flwr[simulation]>=1.14.0", - "flwr-datasets[vision]>=0.4.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr[simulation]>=1.15.0", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", "wandb", ] diff --git a/examples/flowertune-llm/pyproject.toml b/examples/flowertune-llm/pyproject.toml index 4925f3cba15a..e66a020027fd 100644 --- a/examples/flowertune-llm/pyproject.toml +++ b/examples/flowertune-llm/pyproject.toml @@ -8,14 +8,15 @@ version = "1.0.0" description = "FlowerTune LLM: Federated LLM Fine-tuning with Flower" license = "Apache-2.0" dependencies = [ - "flwr[simulation]==1.12.0", - "flwr-datasets>=0.3.0", + "flwr[simulation]==1.15.0", + "flwr-datasets>=0.5.0", + "torch==2.3.1", "trl==0.8.1", - "bitsandbytes==0.43.0", + "bitsandbytes==0.45.0", "scipy==1.13.0", "peft==0.6.2", "fschat[model_worker,webui]==0.2.35", - "transformers==4.39.3", + "transformers==4.47.0", "sentencepiece==0.2.0", "omegaconf==2.3.0", "hf_transfer==0.1.8", diff --git a/examples/flowertune-vit/pyproject.toml b/examples/flowertune-vit/pyproject.toml index bf280de8af95..9c7934a33362 100644 --- a/examples/flowertune-vit/pyproject.toml +++ b/examples/flowertune-vit/pyproject.toml @@ -8,10 +8,10 @@ version = "1.0.0" description = "Federated Finetuning of a Vision Transformer with Flower" license = "Apache-2.0" dependencies = [ - "flwr[simulation]==1.12.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr[simulation]>=1.15.0", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/opacus/pyproject.toml b/examples/opacus/pyproject.toml index 8d49b7c97470..e563b2cae9bb 100644 --- a/examples/opacus/pyproject.toml +++ b/examples/opacus/pyproject.toml @@ -9,9 +9,9 @@ description = "Sample-level Differential Privacy with Opacus in Flower" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.1.1", - "torchvision==0.16.1", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", "opacus==v1.4.1", ] diff --git a/examples/pytorch-federated-variational-autoencoder/pyproject.toml b/examples/pytorch-federated-variational-autoencoder/pyproject.toml index 6c50050828a3..b8774bfdfd14 100644 --- a/examples/pytorch-federated-variational-autoencoder/pyproject.toml +++ b/examples/pytorch-federated-variational-autoencoder/pyproject.toml @@ -9,9 +9,9 @@ description = "Federated Variational Autoencoder Example with PyTorch and Flower license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/quickstart-fastai/pyproject.toml b/examples/quickstart-fastai/pyproject.toml index 49b903b7590c..2c98b3aba522 100644 --- a/examples/quickstart-fastai/pyproject.toml +++ b/examples/quickstart-fastai/pyproject.toml @@ -9,10 +9,10 @@ description = "Federated Learning with Fastai and Flower (Quickstart Example)" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "fastai==2.7.14", - "torch==2.2.0", - "torchvision==0.17.0", + "flwr-datasets[vision]>=0.5.0", + "fastai==2.7.18", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/quickstart-huggingface/pyproject.toml b/examples/quickstart-huggingface/pyproject.toml index 55b54d894f63..f2ee605086ca 100644 --- a/examples/quickstart-huggingface/pyproject.toml +++ b/examples/quickstart-huggingface/pyproject.toml @@ -13,7 +13,7 @@ authors = [ ] dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets>=0.3.0", + "flwr-datasets>=0.5.0", "torch==2.4.0", "transformers>=4.30.0,<5.0", "evaluate>=0.4.0,<1.0", diff --git a/examples/quickstart-jax/pyproject.toml b/examples/quickstart-jax/pyproject.toml index 202318078c16..666df0b0e626 100644 --- a/examples/quickstart-jax/pyproject.toml +++ b/examples/quickstart-jax/pyproject.toml @@ -9,7 +9,7 @@ description = "" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.4.0", + "flwr-datasets[vision]>=0.5.0", "datasets>=2.21.0", "jax==0.4.31", "jaxlib==0.4.31", diff --git a/examples/quickstart-lerobot/pyproject.toml b/examples/quickstart-lerobot/pyproject.toml index 929d4bb51624..e8b095160ef8 100644 --- a/examples/quickstart-lerobot/pyproject.toml +++ b/examples/quickstart-lerobot/pyproject.toml @@ -16,7 +16,7 @@ authors = [ ] dependencies = [ - "flwr[simulation]==1.14.0", + "flwr[simulation]==1.15.0", "transformers>=4.30.0,<5.0", "lerobot[pusht] @ git+https://github.com/huggingface/lerobot.git@96c7052777aca85d4e55dfba8f81586103ba8f61", "flwr-datasets>=0.5.0", diff --git a/examples/quickstart-mlx/pyproject.toml b/examples/quickstart-mlx/pyproject.toml index 1fbae7a93238..cd8ae5cbadde 100644 --- a/examples/quickstart-mlx/pyproject.toml +++ b/examples/quickstart-mlx/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Learning with MLX and Flower (Quickstart Example)" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "mlx==0.21.1", ] diff --git a/examples/quickstart-monai/pyproject.toml b/examples/quickstart-monai/pyproject.toml index c5d0410234b9..3b9cc85c5a27 100644 --- a/examples/quickstart-monai/pyproject.toml +++ b/examples/quickstart-monai/pyproject.toml @@ -9,9 +9,10 @@ description = "Federated Learning with MONAI and Flower (Quickstart Example)" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "monai==1.3.2", "filelock==3.15.4", + "numpy<2.0.0", ] [tool.hatch.build.targets.wheel] diff --git a/examples/quickstart-pandas/pyproject.toml b/examples/quickstart-pandas/pyproject.toml index 39e3d7bae540..34acdb5cf410 100644 --- a/examples/quickstart-pandas/pyproject.toml +++ b/examples/quickstart-pandas/pyproject.toml @@ -13,9 +13,9 @@ authors = [ ] dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "numpy>=1.26.0", - "pandas==2.0.0", + "flwr-datasets[vision]>=0.5.0", + "numpy>=2.0.2", + "pandas==2.2.3", ] [tool.hatch.build.targets.wheel] diff --git a/examples/quickstart-pytorch-lightning/pyproject.toml b/examples/quickstart-pytorch-lightning/pyproject.toml index d9e271da6277..d70deafe28c7 100644 --- a/examples/quickstart-pytorch-lightning/pyproject.toml +++ b/examples/quickstart-pytorch-lightning/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Learning with PyTorch Lightning and Flower (Quickstart license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "pytorch-lightning<2.0.0; sys_platform == 'darwin'", "pytorch-lightning==1.6.0; sys_platform != 'darwin'", "torch==2.5.1", diff --git a/examples/quickstart-pytorch/pyproject.toml b/examples/quickstart-pytorch/pyproject.toml index d0f2e0df22f8..076a42c6bb52 100644 --- a/examples/quickstart-pytorch/pyproject.toml +++ b/examples/quickstart-pytorch/pyproject.toml @@ -9,9 +9,9 @@ description = "Federated Learning with PyTorch and Flower (Quickstart Example)" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "torch==2.2.1", - "torchvision==0.17.1", + "flwr-datasets[vision]>=0.5.0", + "torch==2.5.1", + "torchvision==0.20.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/quickstart-sklearn-tabular/pyproject.toml b/examples/quickstart-sklearn-tabular/pyproject.toml index de4c552d6c63..7649621ab182 100644 --- a/examples/quickstart-sklearn-tabular/pyproject.toml +++ b/examples/quickstart-sklearn-tabular/pyproject.toml @@ -9,8 +9,8 @@ description = "Federated Learning with scikit-learn and Flower (Quickstart Examp license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", - "scikit-learn>=1.3.0", + "flwr-datasets[vision]>=0.5.0", + "scikit-learn>=1.6.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/quickstart-tensorflow/pyproject.toml b/examples/quickstart-tensorflow/pyproject.toml index 12d06ccd8257..1f1feaaa7517 100644 --- a/examples/quickstart-tensorflow/pyproject.toml +++ b/examples/quickstart-tensorflow/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Learning with Tensorflow/Keras and Flower (Quickstart E license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "tensorflow>=2.9.1, != 2.11.1 ; (platform_machine == \"x86_64\" or platform_machine == \"aarch64\")", "tensorflow-macos>=2.9.1, != 2.11.1 ; sys_platform == \"darwin\" and platform_machine == \"arm64\"", ] diff --git a/examples/sklearn-logreg-mnist/pyproject.toml b/examples/sklearn-logreg-mnist/pyproject.toml index 3ef2cccecf0b..a560d1264167 100644 --- a/examples/sklearn-logreg-mnist/pyproject.toml +++ b/examples/sklearn-logreg-mnist/pyproject.toml @@ -13,9 +13,9 @@ authors = [ ] dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "numpy>=2.0.0", - "scikit-learn~=1.2.2", + "scikit-learn>=1.6.1", ] [tool.hatch.build.targets.wheel] diff --git a/examples/tensorflow-privacy/pyproject.toml b/examples/tensorflow-privacy/pyproject.toml index b094b5abf58a..d2682a57a9c6 100644 --- a/examples/tensorflow-privacy/pyproject.toml +++ b/examples/tensorflow-privacy/pyproject.toml @@ -8,7 +8,7 @@ version = "1.0.0" description = "Sample-level Differential Privacy with Tensorflow-Privacy in Flower" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets[vision]>=0.3.0", + "flwr-datasets[vision]>=0.5.0", "tensorflow-estimator~=2.4", "tensorflow-probability~=0.22.0", "tensorflow>=2.4.0,<=2.15.0", diff --git a/examples/vertical-fl/pyproject.toml b/examples/vertical-fl/pyproject.toml index 69ba9a0969e2..6a9102022559 100644 --- a/examples/vertical-fl/pyproject.toml +++ b/examples/vertical-fl/pyproject.toml @@ -9,7 +9,7 @@ description = "PyTorch Vertical FL with Flower" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets>=0.3.0", + "flwr-datasets>=0.5.0", "pandas==2.2.3", "numpy>=1.26.0", "scikit-learn==1.5.0", diff --git a/examples/vertical-fl/vertical_fl/task.py b/examples/vertical-fl/vertical_fl/task.py index 8e76d9419a8a..700db644b740 100644 --- a/examples/vertical-fl/vertical_fl/task.py +++ b/examples/vertical-fl/vertical_fl/task.py @@ -23,7 +23,7 @@ def _bin_age(age_series): def _extract_title(name_series): - titles = name_series.str.extract(" ([A-Za-z]+)\.", expand=False) + titles = name_series.str.extract(r" ([A-Za-z]+)\.", expand=False) rare_titles = { "Lady", "Countess", diff --git a/examples/xgboost-comprehensive/pyproject.toml b/examples/xgboost-comprehensive/pyproject.toml index 3be323d50451..a440bea3aedb 100644 --- a/examples/xgboost-comprehensive/pyproject.toml +++ b/examples/xgboost-comprehensive/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Learning with XGBoost and Flower (Comprehensive Example license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets>=0.3.0", + "flwr-datasets>=0.5.0", "xgboost>=2.0.0", ] diff --git a/examples/xgboost-quickstart/pyproject.toml b/examples/xgboost-quickstart/pyproject.toml index 281735b1a46e..57396e390fa3 100644 --- a/examples/xgboost-quickstart/pyproject.toml +++ b/examples/xgboost-quickstart/pyproject.toml @@ -9,7 +9,7 @@ description = "Federated Learning with XGBoost and Flower (Quickstart Example)" license = "Apache-2.0" dependencies = [ "flwr[simulation]>=1.15.0", - "flwr-datasets>=0.4.0", + "flwr-datasets>=0.5.0", "xgboost>=2.0.0", ]