scaleoutsystems / fedn

FEDn: An enterprise-ready open source federated learning framework. This repository contains the Python framework, CLI and API.
https://docs.scaleoutsystems.com
Apache License 2.0
143 stars 34 forks source link

Tensorflow 2.13.1 Version Issue with Python 3.8 #617

Open Faizack opened 5 months ago

Faizack commented 5 months ago

Bug Report

Describe the bug I was running the example MNIST TensorFlow and encountered an issue. In Python 3.8, TensorFlow version 2.13.1 is not available.

To Reproduce Steps to reproduce the behavior:

  1. Change TensorFlow version to 2.13.0 manually.

  2. fedn package create --path client

  3. Upload package.tgz in fedn.scaleoutsystems in Compute Package

  4. fedn run build --path client and upload seed model in fed

  5. Run fedn client start -in client.yaml --secure=True --force-ssl.

  6. Observe that python_env.yaml is generated with tensorflow==2.13.1 dependencies.

Expected behavior The script should recognize the available TensorFlow version (2.13.0) and not generate a python_env.yaml file with tensorflow==2.13.1.

issue_2 tensorflow-version issue in 3 8

Environment (please complete the following information):

sgronlund commented 5 months ago

The requirement file in the example directory states that you need to use tensorflow>=2.13.1. Thus, I wouldn't consider this a bug, but a maintainer could argue otherwise as they know more :)

I'd suggest creating a new (and empty) virtual environment and then installing fedn, and finally running pip install -r requirements.txt within the example directory.

https://github.com/scaleoutsystems/fedn/blob/f4b9e1b27f4c0df1852023d192ab3f6c18d04d36/examples/mnist-keras/requirements.txt#L1-L3