diff --git a/.github/workflows/docker-bench-security.yml b/.github/workflows/docker-bench-security.yml new file mode 100644 index 0000000000..3b5211f668 --- /dev/null +++ b/.github/workflows/docker-bench-security.yml @@ -0,0 +1,56 @@ +name: Docker Bench for Security + +on: + pull_request: + branches: [ develop ] + +permissions: + contents: read + +jobs: + build: + runs-on: ubuntu-latest + timeout-minutes: 10 + + steps: + - uses: actions/checkout@v3 + - name: Set up Python 3.8 + uses: actions/setup-python@v3 + with: + python-version: "3.8" + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install . + - name: Clean Docker System + run: | + docker image prune -a -f + docker system prune -a -f + - name: Clone Docker Bench Security Repo + run: git clone https://github.com/docker/docker-bench-security.git + - name: Build Docker Bench Security Image + run: | + cd docker-bench-security + docker build --no-cache -t docker-bench-security . + - name: Create results directory + run: mkdir -p results + - name: Run Docker Bench for Security + run: | + docker run --rm --net host --pid host --userns host --cap-add audit_control \ + -e DOCKER_CONTENT_TRUST=0 \ + -v /etc:/etc:ro \ + -v /lib/systemd/system:/lib/systemd/system:ro \ + -v /usr/bin/containerd:/usr/bin/containerd:ro \ + -v /usr/bin/runc:/usr/bin/runc:ro \ + -v /usr/lib/systemd:/usr/lib/systemd:ro \ + -v /var/lib:/var/lib:ro \ + -v /var/run/docker.sock:/var/run/docker.sock:ro \ + -v "$(pwd)/results:/results" \ + --label docker_bench_security \ + docker-bench-security | tee results/docker_bench_security_report.txt + + - name: Upload Security Bench Report + uses: actions/upload-artifact@v3 + with: + name: docker_bench_security-report + path: results/docker_bench_security_report.txt \ No newline at end of file diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 3781cee31c..1c7f9fe4aa 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,4 +26,4 @@ jobs: python -m pip install --upgrade pip pip install -r linters-requirements.txt - name: Lint using built-in script - run: bash shell/lint.sh + run: bash shell/lint.sh \ No newline at end of file diff --git a/.github/workflows/trivy.yml b/.github/workflows/trivy.yml index 84373f9ba2..07087489a8 100644 --- a/.github/workflows/trivy.yml +++ b/.github/workflows/trivy.yml @@ -30,17 +30,61 @@ jobs: uses: github/codeql-action/upload-sarif@v2 with: sarif_file: 'trivy-results.sarif' + + - name: Install Trivy + run: | + curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sudo sh -s -- -b /usr/local/bin v0.55.0 + + - name: Run Trivy code vulnerability scanner (JSON Output) + run: | + trivy --quiet fs --format json --output trivy-code-results.json --ignore-unfixed --vuln-type os,library --severity CRITICAL,HIGH,MEDIUM,LOW . + + - name: Upload Code Vulnerability Scan Results + uses: actions/upload-artifact@v3 + with: + name: trivy-code-report-json + path: trivy-code-results.json - - name: Run Trivy vulnerability scanner + - name: Run Trivy vulnerability scanner for Docker image (JSON Output) uses: aquasecurity/trivy-action@0.24.0 with: image-ref: 'docker.io/securefederatedai/openfl:${{ github.sha }}' - format: 'table' + format: 'json' + output: 'trivy-docker-results.json' exit-code: '1' ignore-unfixed: true vuln-type: 'os,library' severity: 'CRITICAL,HIGH,MEDIUM,LOW' - - name: Log completion message + - name: Upload Docker Vulnerability Scan + uses: actions/upload-artifact@v3 + with: + name: trivy-docker-report-json + path: trivy-docker-results.json + + - name: Run Trivy code vulnerability scanner (SPDX-JSON Output) run: | - echo "Trivy scan completed. Review the output above for vulnerabilities." + trivy --quiet fs --format spdx-json --output trivy-code-spdx-results.json --ignore-unfixed --vuln-type os,library --severity CRITICAL,HIGH,MEDIUM,LOW . + + - name: Upload Code Vulnerability Scan Results + uses: actions/upload-artifact@v3 + with: + name: trivy-code-spdx-report-json + path: trivy-code-spdx-results.json + + - name: Run Trivy vulnerability scanner for Docker image (SPDX-JSON Output) + uses: aquasecurity/trivy-action@0.24.0 + with: + image-ref: 'docker.io/securefederatedai/openfl:${{ github.sha }}' + format: 'spdx-json' + output: 'trivy-docker-spdx-results.json' + exit-code: '1' + ignore-unfixed: true + vuln-type: 'os,library' + severity: 'CRITICAL,HIGH,MEDIUM,LOW' + + - name: Upload Docker Vulnerability Scan + uses: actions/upload-artifact@v3 + with: + name: trivy-docker-spdx-report-json + path: trivy-docker-spdx-results.json diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000000..9b323cd20d --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,31 @@ +--- +minimum_pre_commit_version: 3.3.3 +repos: + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.4.0 + hooks: + - id: end-of-file-fixer + files: \.py$ + - id: requirements-txt-fixer + - id: check-merge-conflict + - id: check-case-conflict + - id: check-json + files: \.json$ + - id: check-yaml + files: \.yaml$ + - id: debug-statements + - id: pretty-format-json + args: + - --autofix + files: \.json$ + - id: trailing-whitespace + files: \.py$ + - repo: https://github.com/PyCQA/autoflake + rev: v2.2.0 + hooks: + - id: autoflake + args: + - --in-place + - --remove-unused-variables + - --recursive + - --ignore-pass-statements \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3ba8399a9e..ecc1fee5f2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -55,11 +55,12 @@ git clone https://github.com/YOUR_GITHUB_USERNAME/openfl.git cd openfl pip install -U pip setuptools wheel pip install . +pip install -r requirements-linters.txt ``` ## Code style -OpenFL uses [black](https://black.readthedocs.io/en/stable/) and [isort](https://pycqa.github.io/isort/) to format the code. +OpenFL uses [black](https://black.readthedocs.io/en/stable/), [isort](https://pycqa.github.io/isort/) and [precommit](https://pre-commit.com/) to format the code. Run the following command at the **root** directory of the repo to format your code. diff --git a/docs/about/releases.md b/docs/about/releases.md index 40ffb4048a..36995d90df 100644 --- a/docs/about/releases.md +++ b/docs/about/releases.md @@ -1,5 +1,31 @@ # Releases +## 1.6 +[Full Release Notes](https://github.com/securefederatedai/openfl/releases/tag/v1.6) + +### New Features and APIs: +- **Federated LLM fine-tuning**: + - [**Horovod**](https://github.com/securefederatedai/openfl/tree/develop/openfl-workspace/torch_llm_horovod): Use horovod to efficiently train LLMs across multiple private clusters + - **Neuralchat-7b fine-tuning**: Learn how to fine-tune [neuralchat-7b](https://github.com/securefederatedai/openfl/tree/develop/openfl-tutorials/experimental/LLM/neuralchat) using the Intel® Extension for Transformers and the workflow interface. + +- **Workflow API enhancements**: Introducing an experimental [Workspace Export](https://github.com/securefederatedai/openfl/blob/develop/openfl-tutorials/experimental/Workflow_Interface_1001_Workspace_Creation_from_JupyterNotebook.ipynb) feature that can be used to transform a Workflow API-based FL experiment into the TaskRunner API format for running in a distributed deployment. There is also groundwork laid for a future FederatedRuntime implementation for Workflow API, in addition to the currently supported LocalRuntime. +- **Federated Evaluation**: Federated evaluation allows for the assessment of ML models in a federated learning system by validating the model's performance locally on decentralized collaborator nodes, and then aggregating these metrics to gauge overall effectiveness, without compromising data privacy and security. FE is now officially supported by OpenFL, including [example tutorials](https://openfl.readthedocs.io/en/latest/about/features_index/fed_eval.html) on how to use this new feature (via TaskRunner API). + +- **Expanded AI Accelerator Support**: Intel® Data Center GPU Max Series support via the Intel® Extension for PyTorch, including examples for training on datasets such as [MNIST](https://github.com/securefederatedai/openfl/blob/develop/openfl-tutorials/experimental/Workflow_Interface_104_MNIST_XPU.ipynb) (via Workflow API) and [TinyImageNet](https://github.com/securefederatedai/openfl/tree/develop/openfl-tutorials/interactive_api/PyTorch_TinyImageNet_XPU) (via Interactive API) + +- **Improved straggler collaborator handling**: Improvements and bug fixes to aggregator’s fault-tolerance when collaborators stop responding or drop out of a federation. Introducing a cut-off timer-based policy and enabling other policies to be plugged-in. This capability is particularly relevant for large or geo-distributed federations. + +- **fx CLI Improvements**: We have separated the CLI commands are separated for creating a collaborator from the certificate request generation, for offering improved control of the participant setup workflow. + +### Highlighting Community Research + +- **Mitigating backdoor attacks in FL** - [Workflow API example](https://github.com/securefederatedai/openfl/tree/develop/openfl-tutorials/experimental/CrowdGuard) contributed by @perieger (TU Darmstadt) demonstrates how [Crowdguard](https://github.com/TRUST-TUDa/crowdguard) can be used to leverage clients' feedback on individual models, analyze the behavior of neurons in hidden layers, and eliminate poisoned models through an iterative pruning scheme. + +### Enhanced Documentation: + +- **Quickstart Tutorial**: An updated [TaskRunner API quickstart](https://openfl.readthedocs.io/en/latest/get_started/quickstart.html#quick-start) tutorial makes it easier for newcomers to get up and running with built-in workspaces or custom code. +- **FL Plan Description Documentation**: There is now a detailed [FL plan description](https://openfl.readthedocs.io/en/latest/about/features_index/taskrunner.html#federated-learning-plan-fl-plan-settings) in the to our documentation to help users better understand and configure the federated learning process. + ## 1.5.1 [Full Release Notes](https://github.com/securefederatedai/openfl/releases/tag/v1.5.1) diff --git a/docs/docs-requirements.txt b/docs/docs-requirements.txt index 162e5499d6..f5e5832d9d 100644 --- a/docs/docs-requirements.txt +++ b/docs/docs-requirements.txt @@ -1,10 +1,10 @@ # Copyright (C) 2020-2024 Intel Corporation # SPDX-License-Identifier: Apache-2.0 -sphinx-rtd-theme +pygments>=2.7.4 # not directly required, pinned by Snyk to avoid a vulnerability +recommonmark +sphinx>=3.0.4 # not directly required, pinned by Snyk to avoid a vulnerability +sphinx-copybutton sphinx-prompt +sphinx-rtd-theme sphinx_substitution_extensions -sphinx-copybutton sphinxcontrib-mermaid -pygments>=2.7.4 # not directly required, pinned by Snyk to avoid a vulnerability -sphinx>=3.0.4 # not directly required, pinned by Snyk to avoid a vulnerability -recommonmark diff --git a/docs/structurizer_dsl/workspace.json b/docs/structurizer_dsl/workspace.json index 71ac98b00a..2a2a55389f 100644 --- a/docs/structurizer_dsl/workspace.json +++ b/docs/structurizer_dsl/workspace.json @@ -1,509 +1,643 @@ { - "id" : 1, - "name" : "OpenFL", - "description" : "An open framework for Federated Learning.", - "revision" : 0, - "lastModifiedDate" : "2021-08-27T13:28:56Z", - "lastModifiedAgent" : "structurizr-web/2475", - "properties" : { - "structurizr.dsl" : "CndvcmtzcGFjZSAiT3BlbkZMIiAiQW4gb3BlbiBmcmFtZXdvcmsgZm9yIEZlZGVyYXRlZCBMZWFybmluZy4iIHsKICAgIG1vZGVsIHsKICAgICAgICBncm91cCAiQ29udHJvbCIgewogICAgICAgICAgICB1c2VyID0gcGVyc29uICJEYXRhIHNjaWVudGlzdCIgIkEgcGVyc29uIG9yIGdyb3VwIG9mIHBlb3BsZSB1c2luZyBPcGVuRkwiCiAgICAgICAgICAgIHNoYXJkT3duZXIgPSBwZXJzb24gIkNvbGxhYm9yYXRvciBtYW5hZ2VyIiAiRGF0YSBvd25lcidzIHJlcHJlc2VudGF0aXZlIGNvbnRyb2xsaW5nIEVudm95IgogICAgICAgICAgICBjZW50cmFsTWFuYWdlciA9IHBlcnNvbiAiRGlyZWN0b3IgbWFuYWdlciIgCiAgICAgICAgICAgIGdvdmVybm9yID0gc29mdHdhcmVTeXN0ZW0gIkdvdmVybm9yIiAiQ0NGLWJhc2VkIHN5c3RlbSBmb3IgY29ycG9yYXRlIGNsaWVudHMiCiAgICAgICAgfQogICAgICAgIG9wZW5mbCA9IHNvZnR3YXJlU3lzdGVtICJPcGVuRkwiICJBbiBvcGVuIGZyYW1ld29yayBmb3IgRmVkZXJhdGVkIExlYXJuaW5nIiB7CiAgICAgICAgICAgIGFwaUxheWVyID0gY29udGFpbmVyICJQeXRob24gQVBJIGNvbXBvbmVudCIgIkEgc2V0IG9mIHRvb2xzIHRvIHNldHVwIHJlZ2lzdGVyIEZMIEV4cGVyaW1lbnRzIiB7CiAgICAgICAgICAgICAgICBmZWRlcmF0aW9uSW50ZXJmYWNlID0gY29tcG9uZW50ICJGZWRlcmFpb24gSW50ZXJmYWNlIgogICAgICAgICAgICAgICAgZXhwZXJpbWVudEludGVyZmFjZSA9IGNvbXBvbmVudCAiRXhwZXJpbWVudCBJbnRlcmZhY2UiCiAgICAgICAgICAgICAgICAjIFRhc2tJbnRlcmZhY2UgPSBjb21wb25lbnQgIiIKICAgICAgICAgICAgfQoKICAgICAgICAgICAgZ3JvdXAgIkNlbnRyYWwgbm9kZSIgewogICAgICAgICAgICAgICAgZGlyZWN0b3IgPSBjb250YWluZXIgIkRpcmVjdG9yIiAiQSBsb25nLWxpdmluZyBlbnRpdHkgdGhhdCBjYW4gc3Bhd24gYWdncmVnYXRvcnMiCiAgICAgICAgICAgICAgICBhZ2dyZWdhdG9yID0gY29udGFpbmVyICJBZ2dyZWdhdG9yIiAiTW9kZWwgc2VydmVyIGFuZCBjb2xsYWJvcmF0b3Igb3JjaGVzdHJhdG9yInsKICAgICAgICAgICAgICAgICAgICBhc3NpZ25lciA9IGNvbXBvbmVudCAiVGFzayBBc3NpZ25lciIgIkRlY2lkZXMgdGhlIHBvbGljeSBmb3Igd2hpY2ggY29sbGFib3JhdG9ycyBzaG91bGQgcnVuIEZMIHRhc2tzIgogICAgICAgICAgICAgICAgICAgIGdycGNTZXJ2ZXIgPSBjb21wb25lbnQgImdSUEMgU2VydmVyIgogICAgICAgICAgICAgICAgfQogICAgICAgICAgICB9CiAgICAgICAgICAgIGdyb3VwICJDb2xsYWJvcmF0b3Igbm9kZSIgewogICAgICAgICAgICAgICAgZW52b3kgPSBjb250YWluZXIgIkVudm95IiAiQSBsb25nLWxpdmluZyBlbnRpdHkgdGhhdCBjYW4gYWRhcHQgYSBsb2NhbCBkYXRhIHNldCBhbmQgc3Bhd24gY29sbGFib3JhdG9ycyIgewogICAgICAgICAgICAgICAgICAgIHNoYXJkRGVzY3JpcHRvciA9IGNvbXBvbmVudCAiU2hhcmQgRGVzY3JpcHRvciIgIkRhdGEgbWFuYWdlcidzIGludGVyZmFjZSBhaW1lZCB0byB1bmlmeSBkYXRhIGFjY2VzcyIgewogICAgICAgICAgICAgICAgICAgICAgICB0YWdzICJJbnRlcmZhY2UiCiAgICAgICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgY29sbGFib3JhdG9yID0gY29udGFpbmVyICJDb2xsYWJvcmF0b3IiICJBY3RvciBleGVjdXRpbmcgdGFza3Mgb24gbG9jYWwgZGF0YSBpbnNpZGUgb25lIGV4cGVyaW1lbnQiIHsKICAgICAgICAgICAgICAgICAgICBwbHVnaW5NYW5hZ2VyID0gY29tcG9uZW50ICJQbHVnaW4gTWFuYWdlciIKICAgICAgICAgICAgICAgICAgICB0YXNrUnVubmVyID0gY29tcG9uZW50ICJUYXNrIFJ1bm5lciIKICAgICAgICAgICAgICAgICAgICB0ZW5zb3JEQiA9IGNvbXBvbmVudCAiVGVuc29yIERhdGEgQmFzZSIKICAgICAgICAgICAgICAgICAgICB0ZW5zb3JDb2RlYyA9IGNvbXBvbmVudCAiVGVuc29yQ29kZWMiCiAgICAgICAgICAgICAgICAgICAgZ3JwY0NsaWVudCA9IGNvbXBvbmVudCAiZ1JQQyBDbGllbnQiCiAgICAgICAgICAgICAgICAgICAgZnJhbWV3b3JrQWRhcHRlciA9IGNvbXBvbmVudCAiRnJhbWV3b3JrIEFkYXB0ZXIiCiAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgIH0KICAgICAgICB9CiAgICAgICAgY29uZmlnID0gZWxlbWVudCAiQ29uZmlnIGZpbGUiCgogICAgICAgICMgcmVsYXRpb25zaGlwcyBiZXR3ZWVuIHBlb3BsZSBhbmQgc29mdHdhcmUgc3lzdGVtcwogICAgICAgIHVzZXIgLT4gb3BlbmZsICJDb250cm9scyBGZWRhcmF0aW9ucy4gUHJvdmlkZXMgRkwgcGxhbnMsIHRhc2tzLCBtb2RlbHMsIGRhdGEiCiAgICAgICAgZ292ZXJub3IgLT4gb3BlbmZsICJDb250cm9scyBGZWRhcmF0aW9ucyIKCiAgICAgICAgIyByZWxhdGlvbnNoaXBzIHRvL2Zyb20gY29udGFpbmVycwogICAgICAgIHVzZXIgLT4gYXBpTGF5ZXIgIlByb3ZpZGVzIEZMIFBsYW5zLCBUYXNrcywgTW9kZWxzLCBEYXRhTG9hZGVycyIKICAgICAgICBzaGFyZE93bmVyIC0+IGVudm95ICJMYXVuY2hlcy4gUHJvdmlkZXMgbG9jYWwgZGF0YXNldCBTaGFyZERlc2NyaXB0b3JzIgogICAgICAgIGNlbnRyYWxNYW5hZ2VyIC0+IGRpcmVjdG9yICJMYXVuY2hlcy4gU2V0cyB1cCBnbG9iYWwgRmVkZXJhdGlvbiBzZXR0aW5ncyIKICAgICAgICBhcGlMYXllciAtPiBkaXJlY3RvciAiUmVnaXN0ZXJzIEZMIGV4cGVyaW1lbnRzIgogICAgICAgIGRpcmVjdG9yIC0+IGFwaUxheWVyICJTZW5kcyBpbmZvcm1hdGlvbiBhYm91dCB0aGUgRmVkZXJhdGlvbi4gUmV0dXJucyB0cmFpbmluZyBhcnRpZmFjdHMuIgogICAgICAgIGRpcmVjdG9yIC0+IGFnZ3JlZ2F0b3IgIkNyZWF0ZXMgYW4gaW5zdGFuY2UgdG8gbWFpbnRhaW4gYW4gRkwgZXhwZXJpbWVudCIKICAgICAgICBlbnZveSAtPiBjb2xsYWJvcmF0b3IgIkNyZWF0ZXMgYW4gaW5zdGFuY2UgdG8gbWFpbnRhaW4gYW4gRkwgZXhwZXJpbWVudCIKICAgICAgICBlbnZveSAtPiBkaXJlY3RvciAiQ29tbXVuaWNhdGVzIGRhdGFzZXQgaW5mbywgU2VuZHMgc3RhdHVzIHVwZGF0ZXMiCiAgICAgICAgZGlyZWN0b3IgLT4gZW52b3kgIkFwcHJvdmVzLCBTZW5kcyBGTCBleHBlcmltZW50cyIKICAgICAgICBhZ2dyZWdhdG9yIC0+IGNvbGxhYm9yYXRvciAiU2VuZHMgdGFza3MgYW5kIGluaXRpYWwgdGVuc29ycyIKICAgICAgICBjb2xsYWJvcmF0b3IgLT4gYWdncmVnYXRvciAiU2VuZHMgbG9jYWxseSB0dW5lZCB0ZW5zb3JzIGFuZCB0cmFpbmluZyBtZXRyaWNzIgoKCiAgICAgICAgIyByZWxhdGlvbnNoaXBzIHRvL2Zyb20gY29tcG9uZW50cwogICAgICAgIGVudm95IC0+IHRhc2tSdW5uZXIgIlByb3ZpZGVzIHRhc2tzJyBkZWZlbml0aW9ucyIKICAgICAgICBncnBjQ2xpZW50IC0+IHRhc2tSdW5uZXIgIkludm9rZXMgc29tZSB0YXNrcyBmb3IgdGhlIHJvdW5kIgogICAgICAgIGFnZ3JlZ2F0b3IgLT4gZ3JwY0NsaWVudCAiQ29tbXVuaWNhdGVzIgogICAgfQoKICAgIHZpZXdzCiAgICAgICAgdGhlbWUgZGVmYXVsdAoKICAgICAgICBzeXN0ZW1jb250ZXh0IG9wZW5mbCAiU3lzdGVtQ29udGV4dCIgewogICAgICAgICAgICBpbmNsdWRlICoKICAgICAgICAgICAgYXV0b0xheW91dAogICAgICAgICAgICAKICAgICAgICB9CgogICAgICAgIGNvbnRhaW5lciBvcGVuZmwgIkNvbnRhaW5lcnMiIHsKICAgICAgICAgICAgaW5jbHVkZSAqCiAgICAgICAgICAgICMgaW5jbHVkZSBjb25maWcKICAgICAgICAgICAgIyBhdXRvTGF5b3V0CiAgICAgICAgfQoKICAgICAgICBjb21wb25lbnQgY29sbGFib3JhdG9yICJDb2xsYWJvcmF0b3IiIHsKICAgICAgICAgICAgaW5jbHVkZSAqCiAgICAgICAgICAgIGF1dG9MYXlvdXQKICAgICAgICB9CgogICAgICAgIGNvbXBvbmVudCBhcGlMYXllciAiQVBJIiB7CiAgICAgICAgICAgIGluY2x1ZGUgKgogICAgICAgICAgICBhdXRvTGF5b3V0CiAgICAgICAgfQoKICAgICAgICBjb21wb25lbnQgZW52b3kgIkVudm95IiB7CiAgICAgICAgICAgIGluY2x1ZGUgKgogICAgICAgICAgICBhdXRvTGF5b3V0CiAgICAgICAgfQoKfQoK" - }, - "configuration" : { }, - "model" : { - "people" : [ { - "id" : "2", - "tags" : "Element,Person", - "name" : "Collaborator manager", - "description" : "Data owner's representative controlling Envoy", - "relationships" : [ { - "id" : "26", - "tags" : "Relationship", - "sourceId" : "2", - "destinationId" : "13", - "description" : "Launches. Provides local dataset ShardDescriptors" - }, { - "id" : "27", - "tags" : "Relationship", - "sourceId" : "2", - "destinationId" : "5", - "description" : "Launches. Provides local dataset ShardDescriptors" - } ], - "group" : "Control", - "location" : "Unspecified" - }, { - "id" : "1", - "tags" : "Element,Person", - "name" : "Data scientist", - "description" : "A person or group of people using OpenFL", - "relationships" : [ { - "id" : "25", - "tags" : "Relationship", - "sourceId" : "1", - "destinationId" : "6", - "description" : "Provides FL Plans, Tasks, Models, DataLoaders" - }, { - "id" : "23", - "tags" : "Relationship", - "sourceId" : "1", - "destinationId" : "5", - "description" : "Controls Fedarations. Provides FL plans, tasks, models, data" - } ], - "group" : "Control", - "location" : "Unspecified" - }, { - "id" : "3", - "tags" : "Element,Person", - "name" : "Director manager", - "relationships" : [ { - "id" : "29", - "tags" : "Relationship", - "sourceId" : "3", - "destinationId" : "5", - "description" : "Launches. Sets up global Federation settings" - }, { - "id" : "28", - "tags" : "Relationship", - "sourceId" : "3", - "destinationId" : "9", - "description" : "Launches. Sets up global Federation settings" - } ], - "group" : "Control", - "location" : "Unspecified" - } ], - "softwareSystems" : [ { - "id" : "4", - "tags" : "Element,Software System", - "name" : "Governor", - "description" : "CCF-based system for corporate clients", - "relationships" : [ { - "id" : "24", - "tags" : "Relationship", - "sourceId" : "4", - "destinationId" : "5", - "description" : "Controls Fedarations" - } ], - "group" : "Control", - "location" : "Unspecified" - }, { - "id" : "5", - "tags" : "Element,Software System", - "name" : "OpenFL", - "description" : "An open framework for Federated Learning", - "location" : "Unspecified", - "containers" : [ { - "id" : "10", - "tags" : "Element,Container", - "name" : "Aggregator", - "description" : "Model server and collaborator orchestrator", - "relationships" : [ { - "id" : "40", - "tags" : "Relationship", - "sourceId" : "10", - "destinationId" : "20", - "description" : "Communicates" - }, { - "id" : "36", - "tags" : "Relationship", - "sourceId" : "10", - "destinationId" : "15", - "description" : "Sends tasks and initial tensors" - } ], - "group" : "Central node", - "components" : [ { - "id" : "11", - "tags" : "Element,Component", - "name" : "Task Assigner", - "description" : "Decides the policy for which collaborators should run FL tasks", - "size" : 0 - }, { - "id" : "12", - "tags" : "Element,Component", - "name" : "gRPC Server", - "size" : 0 - } ] - }, { - "id" : "15", - "tags" : "Element,Container", - "name" : "Collaborator", - "description" : "Actor executing tasks on local data inside one experiment", - "relationships" : [ { - "id" : "37", - "tags" : "Relationship", - "sourceId" : "15", - "destinationId" : "10", - "description" : "Sends locally tuned tensors and training metrics" - } ], - "group" : "Collaborator node", - "components" : [ { - "id" : "16", - "tags" : "Element,Component", - "name" : "Plugin Manager", - "size" : 0 - }, { - "id" : "21", - "tags" : "Element,Component", - "name" : "Framework Adapter", - "size" : 0 - }, { - "id" : "18", - "tags" : "Element,Component", - "name" : "Tensor Data Base", - "size" : 0 - }, { - "id" : "20", - "tags" : "Element,Component", - "name" : "gRPC Client", - "relationships" : [ { - "id" : "39", - "tags" : "Relationship", - "sourceId" : "20", - "destinationId" : "17", - "description" : "Invokes some tasks for the round" - } ], - "size" : 0 - }, { - "id" : "19", - "tags" : "Element,Component", - "name" : "TensorCodec", - "size" : 0 - }, { - "id" : "17", - "tags" : "Element,Component", - "name" : "Task Runner", - "size" : 0 - } ] - }, { - "id" : "6", - "tags" : "Element,Container", - "name" : "Python API component", - "description" : "A set of tools to setup register FL Experiments", - "relationships" : [ { - "id" : "30", - "tags" : "Relationship", - "sourceId" : "6", - "destinationId" : "9", - "description" : "Registers FL experiments" - } ], - "components" : [ { - "id" : "8", - "tags" : "Element,Component", - "name" : "Experiment Interface", - "size" : 0 - }, { - "id" : "7", - "tags" : "Element,Component", - "name" : "Federaion Interface", - "size" : 0 - } ] - }, { - "id" : "13", - "tags" : "Element,Container", - "name" : "Envoy", - "description" : "A long-living entity that can adapt a local data set and spawn collaborators", - "relationships" : [ { - "id" : "34", - "tags" : "Relationship", - "sourceId" : "13", - "destinationId" : "9", - "description" : "Communicates dataset info, Sends status updates" - }, { - "id" : "38", - "tags" : "Relationship", - "sourceId" : "13", - "destinationId" : "17", - "description" : "Provides tasks' defenitions" - }, { - "id" : "33", - "tags" : "Relationship", - "sourceId" : "13", - "destinationId" : "15", - "description" : "Creates an instance to maintain an FL experiment" - } ], - "group" : "Collaborator node", - "components" : [ { - "id" : "14", - "tags" : "Element,Component,Interface", - "name" : "Shard Descriptor", - "description" : "Data manager's interface aimed to unify data access", - "size" : 0 - } ] - }, { - "id" : "9", - "tags" : "Element,Container", - "name" : "Director", - "description" : "A long-living entity that can spawn aggregators", - "relationships" : [ { - "id" : "31", - "tags" : "Relationship", - "sourceId" : "9", - "destinationId" : "6", - "description" : "Sends information about the Federation. Returns training artifacts." - }, { - "id" : "35", - "tags" : "Relationship", - "sourceId" : "9", - "destinationId" : "13", - "description" : "Approves, Sends FL experiments" - }, { - "id" : "32", - "tags" : "Relationship", - "sourceId" : "9", - "destinationId" : "10", - "description" : "Creates an instance to maintain an FL experiment" - } ], - "group" : "Central node" - } ] - } ], - "customElements" : [ { - "id" : "22", - "tags" : "Element", - "name" : "Config file" - } ] - }, - "documentation" : { }, - "views" : { - "systemContextViews" : [ { - "softwareSystemId" : "5", - "key" : "SystemContext", - "paperSize" : "A4_Landscape", - "dimensions" : { - "width" : 3358, - "height" : 1454 - }, - "automaticLayout" : { - "implementation" : "Graphviz", - "rankDirection" : "TopBottom", - "rankSeparation" : 300, - "nodeSeparation" : 300, - "edgeSeparation" : 0, - "vertices" : false + "configuration": {}, + "description": "An open framework for Federated Learning.", + "documentation": {}, + "id": 1, + "lastModifiedAgent": "structurizr-web/2475", + "lastModifiedDate": "2021-08-27T13:28:56Z", + "model": { + "customElements": [ + { + "id": "22", + "name": "Config file", + "tags": "Element" + } + ], + "people": [ + { + "description": "Data owner's representative controlling Envoy", + "group": "Control", + "id": "2", + "location": "Unspecified", + "name": "Collaborator manager", + "relationships": [ + { + "description": "Launches. Provides local dataset ShardDescriptors", + "destinationId": "13", + "id": "26", + "sourceId": "2", + "tags": "Relationship" + }, + { + "description": "Launches. Provides local dataset ShardDescriptors", + "destinationId": "5", + "id": "27", + "sourceId": "2", + "tags": "Relationship" + } + ], + "tags": "Element,Person" }, - "enterpriseBoundaryVisible" : true, - "elements" : [ { - "id" : "1", - "x" : 2604, - "y" : 277 - }, { - "id" : "2", - "x" : 1854, - "y" : 277 - }, { - "id" : "3", - "x" : 1104, - "y" : 277 - }, { - "id" : "4", - "x" : 354, - "y" : 277 - }, { - "id" : "5", - "x" : 1479, - "y" : 877 - } ], - "relationships" : [ { - "id" : "29" - }, { - "id" : "27" - }, { - "id" : "24", - "vertices" : [ { - "x" : 954, - "y" : 681 - } ] - }, { - "id" : "23", - "vertices" : [ { - "x" : 2454, - "y" : 681 - } ] - } ] - } ], - "containerViews" : [ { - "softwareSystemId" : "5", - "key" : "Containers", - "dimensions" : { - "width" : 3104, - "height" : 2546 + { + "description": "A person or group of people using OpenFL", + "group": "Control", + "id": "1", + "location": "Unspecified", + "name": "Data scientist", + "relationships": [ + { + "description": "Provides FL Plans, Tasks, Models, DataLoaders", + "destinationId": "6", + "id": "25", + "sourceId": "1", + "tags": "Relationship" + }, + { + "description": "Controls Fedarations. Provides FL plans, tasks, models, data", + "destinationId": "5", + "id": "23", + "sourceId": "1", + "tags": "Relationship" + } + ], + "tags": "Element,Person" }, - "externalSoftwareSystemBoundariesVisible" : true, - "elements" : [ { - "id" : "1", - "x" : 890, - "y" : 200 - }, { - "id" : "13", - "x" : 1740, - "y" : 1320 - }, { - "id" : "2", - "x" : 2470, - "y" : 1265 - }, { - "id" : "3", - "x" : 230, - "y" : 1270 - }, { - "id" : "15", - "x" : 1740, - "y" : 1855 - }, { - "id" : "6", - "x" : 880, - "y" : 760 - }, { - "id" : "9", - "x" : 880, - "y" : 1320 - }, { - "id" : "10", - "x" : 880, - "y" : 1855 - } ], - "relationships" : [ { - "id" : "28" - }, { - "id" : "26" - }, { - "id" : "37", - "vertices" : [ { - "x" : 1535, - "y" : 1940 - } ] - }, { - "id" : "25" - }, { - "id" : "36", - "vertices" : [ { - "x" : 1565, - "y" : 2090 - } ] - }, { - "id" : "35", - "vertices" : [ { - "x" : 1550, - "y" : 1530 - } ] - }, { - "id" : "34", - "vertices" : [ { - "x" : 1530, - "y" : 1360 - } ] - }, { - "id" : "33" - }, { - "id" : "32" - }, { - "id" : "31", - "vertices" : [ { - "x" : 1215, - "y" : 1185 - } ] - }, { - "id" : "30", - "vertices" : [ { - "x" : 995, - "y" : 1175 - } ] - } ] - } ], - "componentViews" : [ { - "key" : "Collaborator", - "automaticLayout" : { - "implementation" : "Graphviz", - "rankDirection" : "TopBottom", - "rankSeparation" : 300, - "nodeSeparation" : 300, - "edgeSeparation" : 0, - "vertices" : false + { + "group": "Control", + "id": "3", + "location": "Unspecified", + "name": "Director manager", + "relationships": [ + { + "description": "Launches. Sets up global Federation settings", + "destinationId": "5", + "id": "29", + "sourceId": "3", + "tags": "Relationship" + }, + { + "description": "Launches. Sets up global Federation settings", + "destinationId": "9", + "id": "28", + "sourceId": "3", + "tags": "Relationship" + } + ], + "tags": "Element,Person" + } + ], + "softwareSystems": [ + { + "description": "CCF-based system for corporate clients", + "group": "Control", + "id": "4", + "location": "Unspecified", + "name": "Governor", + "relationships": [ + { + "description": "Controls Fedarations", + "destinationId": "5", + "id": "24", + "sourceId": "4", + "tags": "Relationship" + } + ], + "tags": "Element,Software System" }, - "containerId" : "15", - "externalContainerBoundariesVisible" : true, - "elements" : [ { - "id" : "13", - "x" : 0, - "y" : 0 - }, { - "id" : "16", - "x" : 0, - "y" : 0 - }, { - "id" : "17", - "x" : 0, - "y" : 0 - }, { - "id" : "18", - "x" : 0, - "y" : 0 - }, { - "id" : "19", - "x" : 0, - "y" : 0 - }, { - "id" : "20", - "x" : 0, - "y" : 0 - }, { - "id" : "21", - "x" : 0, - "y" : 0 - }, { - "id" : "10", - "x" : 0, - "y" : 0 - } ], - "relationships" : [ { - "id" : "40" - }, { - "id" : "38" - }, { - "id" : "39" - } ] - }, { - "key" : "API", - "automaticLayout" : { - "implementation" : "Graphviz", - "rankDirection" : "TopBottom", - "rankSeparation" : 300, - "nodeSeparation" : 300, - "edgeSeparation" : 0, - "vertices" : false + { + "containers": [ + { + "components": [ + { + "description": "Decides the policy for which collaborators should run FL tasks", + "id": "11", + "name": "Task Assigner", + "size": 0, + "tags": "Element,Component" + }, + { + "id": "12", + "name": "gRPC Server", + "size": 0, + "tags": "Element,Component" + } + ], + "description": "Model server and collaborator orchestrator", + "group": "Central node", + "id": "10", + "name": "Aggregator", + "relationships": [ + { + "description": "Communicates", + "destinationId": "20", + "id": "40", + "sourceId": "10", + "tags": "Relationship" + }, + { + "description": "Sends tasks and initial tensors", + "destinationId": "15", + "id": "36", + "sourceId": "10", + "tags": "Relationship" + } + ], + "tags": "Element,Container" + }, + { + "components": [ + { + "id": "16", + "name": "Plugin Manager", + "size": 0, + "tags": "Element,Component" + }, + { + "id": "21", + "name": "Framework Adapter", + "size": 0, + "tags": "Element,Component" + }, + { + "id": "18", + "name": "Tensor Data Base", + "size": 0, + "tags": "Element,Component" + }, + { + "id": "20", + "name": "gRPC Client", + "relationships": [ + { + "description": "Invokes some tasks for the round", + "destinationId": "17", + "id": "39", + "sourceId": "20", + "tags": "Relationship" + } + ], + "size": 0, + "tags": "Element,Component" + }, + { + "id": "19", + "name": "TensorCodec", + "size": 0, + "tags": "Element,Component" + }, + { + "id": "17", + "name": "Task Runner", + "size": 0, + "tags": "Element,Component" + } + ], + "description": "Actor executing tasks on local data inside one experiment", + "group": "Collaborator node", + "id": "15", + "name": "Collaborator", + "relationships": [ + { + "description": "Sends locally tuned tensors and training metrics", + "destinationId": "10", + "id": "37", + "sourceId": "15", + "tags": "Relationship" + } + ], + "tags": "Element,Container" + }, + { + "components": [ + { + "id": "8", + "name": "Experiment Interface", + "size": 0, + "tags": "Element,Component" + }, + { + "id": "7", + "name": "Federaion Interface", + "size": 0, + "tags": "Element,Component" + } + ], + "description": "A set of tools to setup register FL Experiments", + "id": "6", + "name": "Python API component", + "relationships": [ + { + "description": "Registers FL experiments", + "destinationId": "9", + "id": "30", + "sourceId": "6", + "tags": "Relationship" + } + ], + "tags": "Element,Container" + }, + { + "components": [ + { + "description": "Data manager's interface aimed to unify data access", + "id": "14", + "name": "Shard Descriptor", + "size": 0, + "tags": "Element,Component,Interface" + } + ], + "description": "A long-living entity that can adapt a local data set and spawn collaborators", + "group": "Collaborator node", + "id": "13", + "name": "Envoy", + "relationships": [ + { + "description": "Communicates dataset info, Sends status updates", + "destinationId": "9", + "id": "34", + "sourceId": "13", + "tags": "Relationship" + }, + { + "description": "Provides tasks' defenitions", + "destinationId": "17", + "id": "38", + "sourceId": "13", + "tags": "Relationship" + }, + { + "description": "Creates an instance to maintain an FL experiment", + "destinationId": "15", + "id": "33", + "sourceId": "13", + "tags": "Relationship" + } + ], + "tags": "Element,Container" + }, + { + "description": "A long-living entity that can spawn aggregators", + "group": "Central node", + "id": "9", + "name": "Director", + "relationships": [ + { + "description": "Sends information about the Federation. Returns training artifacts.", + "destinationId": "6", + "id": "31", + "sourceId": "9", + "tags": "Relationship" + }, + { + "description": "Approves, Sends FL experiments", + "destinationId": "13", + "id": "35", + "sourceId": "9", + "tags": "Relationship" + }, + { + "description": "Creates an instance to maintain an FL experiment", + "destinationId": "10", + "id": "32", + "sourceId": "9", + "tags": "Relationship" + } + ], + "tags": "Element,Container" + } + ], + "description": "An open framework for Federated Learning", + "id": "5", + "location": "Unspecified", + "name": "OpenFL", + "tags": "Element,Software System" + } + ] + }, + "name": "OpenFL", + "properties": { + "structurizr.dsl": "CndvcmtzcGFjZSAiT3BlbkZMIiAiQW4gb3BlbiBmcmFtZXdvcmsgZm9yIEZlZGVyYXRlZCBMZWFybmluZy4iIHsKICAgIG1vZGVsIHsKICAgICAgICBncm91cCAiQ29udHJvbCIgewogICAgICAgICAgICB1c2VyID0gcGVyc29uICJEYXRhIHNjaWVudGlzdCIgIkEgcGVyc29uIG9yIGdyb3VwIG9mIHBlb3BsZSB1c2luZyBPcGVuRkwiCiAgICAgICAgICAgIHNoYXJkT3duZXIgPSBwZXJzb24gIkNvbGxhYm9yYXRvciBtYW5hZ2VyIiAiRGF0YSBvd25lcidzIHJlcHJlc2VudGF0aXZlIGNvbnRyb2xsaW5nIEVudm95IgogICAgICAgICAgICBjZW50cmFsTWFuYWdlciA9IHBlcnNvbiAiRGlyZWN0b3IgbWFuYWdlciIgCiAgICAgICAgICAgIGdvdmVybm9yID0gc29mdHdhcmVTeXN0ZW0gIkdvdmVybm9yIiAiQ0NGLWJhc2VkIHN5c3RlbSBmb3IgY29ycG9yYXRlIGNsaWVudHMiCiAgICAgICAgfQogICAgICAgIG9wZW5mbCA9IHNvZnR3YXJlU3lzdGVtICJPcGVuRkwiICJBbiBvcGVuIGZyYW1ld29yayBmb3IgRmVkZXJhdGVkIExlYXJuaW5nIiB7CiAgICAgICAgICAgIGFwaUxheWVyID0gY29udGFpbmVyICJQeXRob24gQVBJIGNvbXBvbmVudCIgIkEgc2V0IG9mIHRvb2xzIHRvIHNldHVwIHJlZ2lzdGVyIEZMIEV4cGVyaW1lbnRzIiB7CiAgICAgICAgICAgICAgICBmZWRlcmF0aW9uSW50ZXJmYWNlID0gY29tcG9uZW50ICJGZWRlcmFpb24gSW50ZXJmYWNlIgogICAgICAgICAgICAgICAgZXhwZXJpbWVudEludGVyZmFjZSA9IGNvbXBvbmVudCAiRXhwZXJpbWVudCBJbnRlcmZhY2UiCiAgICAgICAgICAgICAgICAjIFRhc2tJbnRlcmZhY2UgPSBjb21wb25lbnQgIiIKICAgICAgICAgICAgfQoKICAgICAgICAgICAgZ3JvdXAgIkNlbnRyYWwgbm9kZSIgewogICAgICAgICAgICAgICAgZGlyZWN0b3IgPSBjb250YWluZXIgIkRpcmVjdG9yIiAiQSBsb25nLWxpdmluZyBlbnRpdHkgdGhhdCBjYW4gc3Bhd24gYWdncmVnYXRvcnMiCiAgICAgICAgICAgICAgICBhZ2dyZWdhdG9yID0gY29udGFpbmVyICJBZ2dyZWdhdG9yIiAiTW9kZWwgc2VydmVyIGFuZCBjb2xsYWJvcmF0b3Igb3JjaGVzdHJhdG9yInsKICAgICAgICAgICAgICAgICAgICBhc3NpZ25lciA9IGNvbXBvbmVudCAiVGFzayBBc3NpZ25lciIgIkRlY2lkZXMgdGhlIHBvbGljeSBmb3Igd2hpY2ggY29sbGFib3JhdG9ycyBzaG91bGQgcnVuIEZMIHRhc2tzIgogICAgICAgICAgICAgICAgICAgIGdycGNTZXJ2ZXIgPSBjb21wb25lbnQgImdSUEMgU2VydmVyIgogICAgICAgICAgICAgICAgfQogICAgICAgICAgICB9CiAgICAgICAgICAgIGdyb3VwICJDb2xsYWJvcmF0b3Igbm9kZSIgewogICAgICAgICAgICAgICAgZW52b3kgPSBjb250YWluZXIgIkVudm95IiAiQSBsb25nLWxpdmluZyBlbnRpdHkgdGhhdCBjYW4gYWRhcHQgYSBsb2NhbCBkYXRhIHNldCBhbmQgc3Bhd24gY29sbGFib3JhdG9ycyIgewogICAgICAgICAgICAgICAgICAgIHNoYXJkRGVzY3JpcHRvciA9IGNvbXBvbmVudCAiU2hhcmQgRGVzY3JpcHRvciIgIkRhdGEgbWFuYWdlcidzIGludGVyZmFjZSBhaW1lZCB0byB1bmlmeSBkYXRhIGFjY2VzcyIgewogICAgICAgICAgICAgICAgICAgICAgICB0YWdzICJJbnRlcmZhY2UiCiAgICAgICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgY29sbGFib3JhdG9yID0gY29udGFpbmVyICJDb2xsYWJvcmF0b3IiICJBY3RvciBleGVjdXRpbmcgdGFza3Mgb24gbG9jYWwgZGF0YSBpbnNpZGUgb25lIGV4cGVyaW1lbnQiIHsKICAgICAgICAgICAgICAgICAgICBwbHVnaW5NYW5hZ2VyID0gY29tcG9uZW50ICJQbHVnaW4gTWFuYWdlciIKICAgICAgICAgICAgICAgICAgICB0YXNrUnVubmVyID0gY29tcG9uZW50ICJUYXNrIFJ1bm5lciIKICAgICAgICAgICAgICAgICAgICB0ZW5zb3JEQiA9IGNvbXBvbmVudCAiVGVuc29yIERhdGEgQmFzZSIKICAgICAgICAgICAgICAgICAgICB0ZW5zb3JDb2RlYyA9IGNvbXBvbmVudCAiVGVuc29yQ29kZWMiCiAgICAgICAgICAgICAgICAgICAgZ3JwY0NsaWVudCA9IGNvbXBvbmVudCAiZ1JQQyBDbGllbnQiCiAgICAgICAgICAgICAgICAgICAgZnJhbWV3b3JrQWRhcHRlciA9IGNvbXBvbmVudCAiRnJhbWV3b3JrIEFkYXB0ZXIiCiAgICAgICAgICAgICAgICB9CiAgICAgICAgICAgIH0KICAgICAgICB9CiAgICAgICAgY29uZmlnID0gZWxlbWVudCAiQ29uZmlnIGZpbGUiCgogICAgICAgICMgcmVsYXRpb25zaGlwcyBiZXR3ZWVuIHBlb3BsZSBhbmQgc29mdHdhcmUgc3lzdGVtcwogICAgICAgIHVzZXIgLT4gb3BlbmZsICJDb250cm9scyBGZWRhcmF0aW9ucy4gUHJvdmlkZXMgRkwgcGxhbnMsIHRhc2tzLCBtb2RlbHMsIGRhdGEiCiAgICAgICAgZ292ZXJub3IgLT4gb3BlbmZsICJDb250cm9scyBGZWRhcmF0aW9ucyIKCiAgICAgICAgIyByZWxhdGlvbnNoaXBzIHRvL2Zyb20gY29udGFpbmVycwogICAgICAgIHVzZXIgLT4gYXBpTGF5ZXIgIlByb3ZpZGVzIEZMIFBsYW5zLCBUYXNrcywgTW9kZWxzLCBEYXRhTG9hZGVycyIKICAgICAgICBzaGFyZE93bmVyIC0+IGVudm95ICJMYXVuY2hlcy4gUHJvdmlkZXMgbG9jYWwgZGF0YXNldCBTaGFyZERlc2NyaXB0b3JzIgogICAgICAgIGNlbnRyYWxNYW5hZ2VyIC0+IGRpcmVjdG9yICJMYXVuY2hlcy4gU2V0cyB1cCBnbG9iYWwgRmVkZXJhdGlvbiBzZXR0aW5ncyIKICAgICAgICBhcGlMYXllciAtPiBkaXJlY3RvciAiUmVnaXN0ZXJzIEZMIGV4cGVyaW1lbnRzIgogICAgICAgIGRpcmVjdG9yIC0+IGFwaUxheWVyICJTZW5kcyBpbmZvcm1hdGlvbiBhYm91dCB0aGUgRmVkZXJhdGlvbi4gUmV0dXJucyB0cmFpbmluZyBhcnRpZmFjdHMuIgogICAgICAgIGRpcmVjdG9yIC0+IGFnZ3JlZ2F0b3IgIkNyZWF0ZXMgYW4gaW5zdGFuY2UgdG8gbWFpbnRhaW4gYW4gRkwgZXhwZXJpbWVudCIKICAgICAgICBlbnZveSAtPiBjb2xsYWJvcmF0b3IgIkNyZWF0ZXMgYW4gaW5zdGFuY2UgdG8gbWFpbnRhaW4gYW4gRkwgZXhwZXJpbWVudCIKICAgICAgICBlbnZveSAtPiBkaXJlY3RvciAiQ29tbXVuaWNhdGVzIGRhdGFzZXQgaW5mbywgU2VuZHMgc3RhdHVzIHVwZGF0ZXMiCiAgICAgICAgZGlyZWN0b3IgLT4gZW52b3kgIkFwcHJvdmVzLCBTZW5kcyBGTCBleHBlcmltZW50cyIKICAgICAgICBhZ2dyZWdhdG9yIC0+IGNvbGxhYm9yYXRvciAiU2VuZHMgdGFza3MgYW5kIGluaXRpYWwgdGVuc29ycyIKICAgICAgICBjb2xsYWJvcmF0b3IgLT4gYWdncmVnYXRvciAiU2VuZHMgbG9jYWxseSB0dW5lZCB0ZW5zb3JzIGFuZCB0cmFpbmluZyBtZXRyaWNzIgoKCiAgICAgICAgIyByZWxhdGlvbnNoaXBzIHRvL2Zyb20gY29tcG9uZW50cwogICAgICAgIGVudm95IC0+IHRhc2tSdW5uZXIgIlByb3ZpZGVzIHRhc2tzJyBkZWZlbml0aW9ucyIKICAgICAgICBncnBjQ2xpZW50IC0+IHRhc2tSdW5uZXIgIkludm9rZXMgc29tZSB0YXNrcyBmb3IgdGhlIHJvdW5kIgogICAgICAgIGFnZ3JlZ2F0b3IgLT4gZ3JwY0NsaWVudCAiQ29tbXVuaWNhdGVzIgogICAgfQoKICAgIHZpZXdzCiAgICAgICAgdGhlbWUgZGVmYXVsdAoKICAgICAgICBzeXN0ZW1jb250ZXh0IG9wZW5mbCAiU3lzdGVtQ29udGV4dCIgewogICAgICAgICAgICBpbmNsdWRlICoKICAgICAgICAgICAgYXV0b0xheW91dAogICAgICAgICAgICAKICAgICAgICB9CgogICAgICAgIGNvbnRhaW5lciBvcGVuZmwgIkNvbnRhaW5lcnMiIHsKICAgICAgICAgICAgaW5jbHVkZSAqCiAgICAgICAgICAgICMgaW5jbHVkZSBjb25maWcKICAgICAgICAgICAgIyBhdXRvTGF5b3V0CiAgICAgICAgfQoKICAgICAgICBjb21wb25lbnQgY29sbGFib3JhdG9yICJDb2xsYWJvcmF0b3IiIHsKICAgICAgICAgICAgaW5jbHVkZSAqCiAgICAgICAgICAgIGF1dG9MYXlvdXQKICAgICAgICB9CgogICAgICAgIGNvbXBvbmVudCBhcGlMYXllciAiQVBJIiB7CiAgICAgICAgICAgIGluY2x1ZGUgKgogICAgICAgICAgICBhdXRvTGF5b3V0CiAgICAgICAgfQoKICAgICAgICBjb21wb25lbnQgZW52b3kgIkVudm95IiB7CiAgICAgICAgICAgIGluY2x1ZGUgKgogICAgICAgICAgICBhdXRvTGF5b3V0CiAgICAgICAgfQoKfQoK" + }, + "revision": 0, + "views": { + "componentViews": [ + { + "automaticLayout": { + "edgeSeparation": 0, + "implementation": "Graphviz", + "nodeSeparation": 300, + "rankDirection": "TopBottom", + "rankSeparation": 300, + "vertices": false + }, + "containerId": "15", + "elements": [ + { + "id": "13", + "x": 0, + "y": 0 + }, + { + "id": "16", + "x": 0, + "y": 0 + }, + { + "id": "17", + "x": 0, + "y": 0 + }, + { + "id": "18", + "x": 0, + "y": 0 + }, + { + "id": "19", + "x": 0, + "y": 0 + }, + { + "id": "20", + "x": 0, + "y": 0 + }, + { + "id": "21", + "x": 0, + "y": 0 + }, + { + "id": "10", + "x": 0, + "y": 0 + } + ], + "externalContainerBoundariesVisible": true, + "key": "Collaborator", + "relationships": [ + { + "id": "40" + }, + { + "id": "38" + }, + { + "id": "39" + } + ] }, - "containerId" : "6", - "externalContainerBoundariesVisible" : true, - "elements" : [ { - "id" : "7", - "x" : 0, - "y" : 0 - }, { - "id" : "8", - "x" : 0, - "y" : 0 - } ] - }, { - "key" : "Envoy", - "automaticLayout" : { - "implementation" : "Graphviz", - "rankDirection" : "TopBottom", - "rankSeparation" : 300, - "nodeSeparation" : 300, - "edgeSeparation" : 0, - "vertices" : false + { + "automaticLayout": { + "edgeSeparation": 0, + "implementation": "Graphviz", + "nodeSeparation": 300, + "rankDirection": "TopBottom", + "rankSeparation": 300, + "vertices": false + }, + "containerId": "6", + "elements": [ + { + "id": "7", + "x": 0, + "y": 0 + }, + { + "id": "8", + "x": 0, + "y": 0 + } + ], + "externalContainerBoundariesVisible": true, + "key": "API" }, - "containerId" : "13", - "externalContainerBoundariesVisible" : true, - "elements" : [ { - "id" : "14", - "x" : 0, - "y" : 0 - } ] - } ], - "configuration" : { - "branding" : { }, - "styles" : { }, - "themes" : [ "https://static.structurizr.com/themes/default/theme.json" ], - "terminology" : { }, - "lastSavedView" : "Containers" - } + { + "automaticLayout": { + "edgeSeparation": 0, + "implementation": "Graphviz", + "nodeSeparation": 300, + "rankDirection": "TopBottom", + "rankSeparation": 300, + "vertices": false + }, + "containerId": "13", + "elements": [ + { + "id": "14", + "x": 0, + "y": 0 + } + ], + "externalContainerBoundariesVisible": true, + "key": "Envoy" + } + ], + "configuration": { + "branding": {}, + "lastSavedView": "Containers", + "styles": {}, + "terminology": {}, + "themes": [ + "https://static.structurizr.com/themes/default/theme.json" + ] + }, + "containerViews": [ + { + "dimensions": { + "height": 2546, + "width": 3104 + }, + "elements": [ + { + "id": "1", + "x": 890, + "y": 200 + }, + { + "id": "13", + "x": 1740, + "y": 1320 + }, + { + "id": "2", + "x": 2470, + "y": 1265 + }, + { + "id": "3", + "x": 230, + "y": 1270 + }, + { + "id": "15", + "x": 1740, + "y": 1855 + }, + { + "id": "6", + "x": 880, + "y": 760 + }, + { + "id": "9", + "x": 880, + "y": 1320 + }, + { + "id": "10", + "x": 880, + "y": 1855 + } + ], + "externalSoftwareSystemBoundariesVisible": true, + "key": "Containers", + "relationships": [ + { + "id": "28" + }, + { + "id": "26" + }, + { + "id": "37", + "vertices": [ + { + "x": 1535, + "y": 1940 + } + ] + }, + { + "id": "25" + }, + { + "id": "36", + "vertices": [ + { + "x": 1565, + "y": 2090 + } + ] + }, + { + "id": "35", + "vertices": [ + { + "x": 1550, + "y": 1530 + } + ] + }, + { + "id": "34", + "vertices": [ + { + "x": 1530, + "y": 1360 + } + ] + }, + { + "id": "33" + }, + { + "id": "32" + }, + { + "id": "31", + "vertices": [ + { + "x": 1215, + "y": 1185 + } + ] + }, + { + "id": "30", + "vertices": [ + { + "x": 995, + "y": 1175 + } + ] + } + ], + "softwareSystemId": "5" + } + ], + "systemContextViews": [ + { + "automaticLayout": { + "edgeSeparation": 0, + "implementation": "Graphviz", + "nodeSeparation": 300, + "rankDirection": "TopBottom", + "rankSeparation": 300, + "vertices": false + }, + "dimensions": { + "height": 1454, + "width": 3358 + }, + "elements": [ + { + "id": "1", + "x": 2604, + "y": 277 + }, + { + "id": "2", + "x": 1854, + "y": 277 + }, + { + "id": "3", + "x": 1104, + "y": 277 + }, + { + "id": "4", + "x": 354, + "y": 277 + }, + { + "id": "5", + "x": 1479, + "y": 877 + } + ], + "enterpriseBoundaryVisible": true, + "key": "SystemContext", + "paperSize": "A4_Landscape", + "relationships": [ + { + "id": "29" + }, + { + "id": "27" + }, + { + "id": "24", + "vertices": [ + { + "x": 954, + "y": 681 + } + ] + }, + { + "id": "23", + "vertices": [ + { + "x": 2454, + "y": 681 + } + ] + } + ], + "softwareSystemId": "5" + } + ] } -} \ No newline at end of file +} diff --git a/linters-requirements.txt b/linters-requirements.txt index 635537644d..f5ea6cbf18 100644 --- a/linters-requirements.txt +++ b/linters-requirements.txt @@ -1,3 +1,4 @@ -isort black -flake8 \ No newline at end of file +flake8 +isort +pre-commit diff --git a/openfl-tutorials/experimental/Global_DP/requirements_global_dp.txt b/openfl-tutorials/experimental/Global_DP/requirements_global_dp.txt index 08265e4831..f5118684aa 100644 --- a/openfl-tutorials/experimental/Global_DP/requirements_global_dp.txt +++ b/openfl-tutorials/experimental/Global_DP/requirements_global_dp.txt @@ -1,9 +1,9 @@ +cloudpickle +matplotlib==3.6.0 numpy==1.23.3 -torch==2.2.0 -torchvision==0.17.0 -torchaudio==2.2.0 opacus==1.5.1 -matplotlib==3.6.0 pillow==10.3.0 pyyaml==6.0 -cloudpickle \ No newline at end of file +torch==2.2.0 +torchaudio==2.2.0 +torchvision==0.17.0 diff --git a/openfl-tutorials/experimental/Privacy_Meter/requirements_privacy_meter.txt b/openfl-tutorials/experimental/Privacy_Meter/requirements_privacy_meter.txt index 815d7023f4..ce4435ea21 100644 --- a/openfl-tutorials/experimental/Privacy_Meter/requirements_privacy_meter.txt +++ b/openfl-tutorials/experimental/Privacy_Meter/requirements_privacy_meter.txt @@ -1,8 +1,8 @@ -torch==2.3.1 -torchvision==0.18.1 +cloudpickle +git+https://github.com/privacytrustlab/ml_privacy_meter.git@ac181a885815f85b3809317c247f422e6596cb4a matplotlib -pillow opacus==1.5.2 -cloudpickle +pillow scikit-learn -git+https://github.com/privacytrustlab/ml_privacy_meter.git@ac181a885815f85b3809317c247f422e6596cb4a +torch==2.3.1 +torchvision==0.18.1 diff --git a/openfl-tutorials/experimental/Vision_Transformer/requirements_vision_transformer.txt b/openfl-tutorials/experimental/Vision_Transformer/requirements_vision_transformer.txt index 1e9a3e3d53..1662f0896d 100644 --- a/openfl-tutorials/experimental/Vision_Transformer/requirements_vision_transformer.txt +++ b/openfl-tutorials/experimental/Vision_Transformer/requirements_vision_transformer.txt @@ -1,4 +1,4 @@ +medmnist==3.0.1 torch==2.3.1 torchvision==0.18.1 -medmnist==3.0.1 -transformers==4.38.0 \ No newline at end of file +transformers==4.38.0 diff --git a/openfl-tutorials/experimental/workflow_interface_requirements.txt b/openfl-tutorials/experimental/workflow_interface_requirements.txt index 988bf7886d..e589695b92 100644 --- a/openfl-tutorials/experimental/workflow_interface_requirements.txt +++ b/openfl-tutorials/experimental/workflow_interface_requirements.txt @@ -1,9 +1,9 @@ -dill==0.3.6 +astor==0.8.1 chardet charset-normalizer +dill==0.3.6 metaflow==2.7.15 nbdev==2.3.12 -astor==0.8.1 ray==2.9.2 torch torchvision diff --git a/openfl-tutorials/interactive_api/Flax_CNN_CIFAR/requirements.txt b/openfl-tutorials/interactive_api/Flax_CNN_CIFAR/requirements.txt index d1aecafc4b..c81a69fea8 100644 --- a/openfl-tutorials/interactive_api/Flax_CNN_CIFAR/requirements.txt +++ b/openfl-tutorials/interactive_api/Flax_CNN_CIFAR/requirements.txt @@ -1,5 +1,5 @@ -tensorflow==2.13 -tensorflow-datasets==4.6.0 -jax --find-links https://storage.googleapis.com/jax-releases/jax_cuda_releases.html +jax jaxlib +tensorflow==2.13 +tensorflow-datasets==4.6.0 diff --git a/openfl-tutorials/interactive_api/HPU/PyTorch_TinyImageNet/envoy/requirements.txt b/openfl-tutorials/interactive_api/HPU/PyTorch_TinyImageNet/envoy/requirements.txt index 3af8318259..7f361a8e94 100644 --- a/openfl-tutorials/interactive_api/HPU/PyTorch_TinyImageNet/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/HPU/PyTorch_TinyImageNet/envoy/requirements.txt @@ -1 +1 @@ -Pillow==10.3.0 \ No newline at end of file +Pillow==10.3.0 diff --git a/openfl-tutorials/interactive_api/MXNet_landmarks/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/MXNet_landmarks/envoy/sd_requirements.txt index b728ea9e23..011e3f5f56 100644 --- a/openfl-tutorials/interactive_api/MXNet_landmarks/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/MXNet_landmarks/envoy/sd_requirements.txt @@ -1,2 +1,2 @@ +kaggle pynvml -kaggle \ No newline at end of file diff --git a/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/envoy/sd_requirements.txt index 3ef08ce100..0a122f85f0 100644 --- a/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/envoy/sd_requirements.txt @@ -1,4 +1,4 @@ +kaggle numpy pillow pynvml -kaggle \ No newline at end of file diff --git a/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/workspace/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/workspace/requirements.txt index a069e9de0c..f4cef897ca 100644 --- a/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_DogsCats_ViT/workspace/requirements.txt @@ -1,6 +1,6 @@ -torch==2.3.1 linformer==0.2.1 +setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability +torch==2.3.1 torchvision==0.18.1 vit-pytorch==0.40.2 -setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability -wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability \ No newline at end of file +wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/PyTorch_Histology/envoy/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_Histology/envoy/requirements.txt index 4c33962e74..069a960a3c 100644 --- a/openfl-tutorials/interactive_api/PyTorch_Histology/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_Histology/envoy/requirements.txt @@ -1,3 +1,3 @@ +numpy==1.22.2 Pillow==10.3.0 tqdm==4.66.3 -numpy==1.22.2 \ No newline at end of file diff --git a/openfl-tutorials/interactive_api/PyTorch_Histology_FedCurv/envoy/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_Histology_FedCurv/envoy/requirements.txt index 9008ff183f..069a960a3c 100644 --- a/openfl-tutorials/interactive_api/PyTorch_Histology_FedCurv/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_Histology_FedCurv/envoy/requirements.txt @@ -1,3 +1,3 @@ +numpy==1.22.2 Pillow==10.3.0 tqdm==4.66.3 -numpy==1.22.2 diff --git a/openfl-tutorials/interactive_api/PyTorch_Huggingface_transformers_SUPERB/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/PyTorch_Huggingface_transformers_SUPERB/envoy/sd_requirements.txt index 2ec4699995..244f7f5080 100644 --- a/openfl-tutorials/interactive_api/PyTorch_Huggingface_transformers_SUPERB/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_Huggingface_transformers_SUPERB/envoy/sd_requirements.txt @@ -1,4 +1,4 @@ datasets==1.14 librosa +numpy==1.22.0 pynvml -numpy==1.22.0 \ No newline at end of file diff --git a/openfl-tutorials/interactive_api/PyTorch_Kvasir_UNet/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/PyTorch_Kvasir_UNet/envoy/sd_requirements.txt index e129ab1966..772cf9f531 100644 --- a/openfl-tutorials/interactive_api/PyTorch_Kvasir_UNet/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_Kvasir_UNet/envoy/sd_requirements.txt @@ -1,3 +1,3 @@ numpy pillow -pynvml \ No newline at end of file +pynvml diff --git a/openfl-tutorials/interactive_api/PyTorch_Lightning_MNIST_GAN/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/PyTorch_Lightning_MNIST_GAN/envoy/sd_requirements.txt index 503a06541d..278e0f55c1 100644 --- a/openfl-tutorials/interactive_api/PyTorch_Lightning_MNIST_GAN/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_Lightning_MNIST_GAN/envoy/sd_requirements.txt @@ -1,7 +1,7 @@ numpy pillow pynvml==11.4.1 +setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability torch==2.3.1 torchvision==0.18.1 -setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability -wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability \ No newline at end of file +wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/PyTorch_LinearRegression/envoy/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_LinearRegression/envoy/requirements.txt index 0baaf04f87..acfef16953 100644 --- a/openfl-tutorials/interactive_api/PyTorch_LinearRegression/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_LinearRegression/envoy/requirements.txt @@ -1,7 +1,7 @@ -openfl>=1.2.1 +mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability numpy>=1.13.3 -torch>=1.13.1 +openfl>=1.2.1 scikit-learn>=0.24.1 -mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability +torch>=1.13.1 wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/PyTorch_LinearRegression/workspace/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_LinearRegression/workspace/requirements.txt index f217759784..fbeabbcfd9 100644 --- a/openfl-tutorials/interactive_api/PyTorch_LinearRegression/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_LinearRegression/workspace/requirements.txt @@ -1,7 +1,7 @@ -openfl>=1.2.1 +jupyterlab numpy>=1.13.3 -torch>=1.13.1 +openfl>=1.2.1 scikit-learn>=0.24.1 -jupyterlab setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability +torch>=1.13.1 wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/PyTorch_MVTec_PatchSVDD/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/PyTorch_MVTec_PatchSVDD/envoy/sd_requirements.txt index 969c33523e..a1e73bfe94 100644 --- a/openfl-tutorials/interactive_api/PyTorch_MVTec_PatchSVDD/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_MVTec_PatchSVDD/envoy/sd_requirements.txt @@ -1,3 +1,3 @@ +imageio numpy pillow -imageio \ No newline at end of file diff --git a/openfl-tutorials/interactive_api/PyTorch_Market_Re-ID/workspace/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_Market_Re-ID/workspace/requirements.txt index c374025be9..62c8356720 100644 --- a/openfl-tutorials/interactive_api/PyTorch_Market_Re-ID/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_Market_Re-ID/workspace/requirements.txt @@ -1,2 +1,2 @@ torch==2.3.1 -torchvision==0.18.1 \ No newline at end of file +torchvision==0.18.1 diff --git a/openfl-tutorials/interactive_api/PyTorch_MedMNIST_3D/envoy/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_MedMNIST_3D/envoy/requirements.txt index c039917814..824405557e 100644 --- a/openfl-tutorials/interactive_api/PyTorch_MedMNIST_3D/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_MedMNIST_3D/envoy/requirements.txt @@ -1,5 +1,5 @@ -medmnist ACSConv +medmnist protobuf>=3.20.2 # not directly required, pinned by Snyk to avoid a vulnerability setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/PyTorch_TinyImageNet/workspace/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_TinyImageNet/workspace/requirements.txt index b5a89e808d..bd0fcb51ad 100644 --- a/openfl-tutorials/interactive_api/PyTorch_TinyImageNet/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_TinyImageNet/workspace/requirements.txt @@ -1,4 +1,4 @@ +setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability torch==2.3.1 torchvision==0.18.1 -setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/PyTorch_TinyImageNet_XPU/workspace/requirements.txt b/openfl-tutorials/interactive_api/PyTorch_TinyImageNet_XPU/workspace/requirements.txt index b5a89e808d..bd0fcb51ad 100644 --- a/openfl-tutorials/interactive_api/PyTorch_TinyImageNet_XPU/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/PyTorch_TinyImageNet_XPU/workspace/requirements.txt @@ -1,4 +1,4 @@ +setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability torch==2.3.1 torchvision==0.18.1 -setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/envoy/sd_requirements.txt b/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/envoy/sd_requirements.txt index fe9e0a000c..5f3956ba14 100644 --- a/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/envoy/sd_requirements.txt +++ b/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/envoy/sd_requirements.txt @@ -1,4 +1,4 @@ gdown==3.13.0 numpy==1.22.2 pandas==1.3.3 -pyarrow==14.0.1 \ No newline at end of file +pyarrow==14.0.1 diff --git a/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/workspace/requirements.txt b/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/workspace/requirements.txt index 4b6c237d85..906c8971fd 100644 --- a/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/Tensorflow_Word_Prediction/workspace/requirements.txt @@ -1,2 +1,2 @@ -tensorflow==2.13 numpy==1.22.2 +tensorflow==2.13 diff --git a/openfl-tutorials/interactive_api/jax_linear_regression/envoy/requirements.txt b/openfl-tutorials/interactive_api/jax_linear_regression/envoy/requirements.txt index 86aea6c296..9af7b85004 100644 --- a/openfl-tutorials/interactive_api/jax_linear_regression/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/jax_linear_regression/envoy/requirements.txt @@ -1,6 +1,6 @@ -openfl==1.3 jax==0.3.13 jaxlib==0.3.10 mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability +openfl==1.3 setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/numpy_linear_regression/envoy/requirements.txt b/openfl-tutorials/interactive_api/numpy_linear_regression/envoy/requirements.txt index 5836d82be4..fb452e0913 100644 --- a/openfl-tutorials/interactive_api/numpy_linear_regression/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/numpy_linear_regression/envoy/requirements.txt @@ -1,5 +1,5 @@ -openfl==1.2.1 -numpy mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability +numpy +openfl==1.2.1 setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/numpy_linear_regression/workspace/requirements.txt b/openfl-tutorials/interactive_api/numpy_linear_regression/workspace/requirements.txt index cfba7a1489..ce2479f563 100644 --- a/openfl-tutorials/interactive_api/numpy_linear_regression/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/numpy_linear_regression/workspace/requirements.txt @@ -1,7 +1,7 @@ -openfl==1.2.1 -numpy jupyterlab matplotlib mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability +numpy +openfl==1.2.1 setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/scikit_learn_linear_regression/envoy/requirements.txt b/openfl-tutorials/interactive_api/scikit_learn_linear_regression/envoy/requirements.txt index f1ad86dd90..40d18d92d5 100644 --- a/openfl-tutorials/interactive_api/scikit_learn_linear_regression/envoy/requirements.txt +++ b/openfl-tutorials/interactive_api/scikit_learn_linear_regression/envoy/requirements.txt @@ -1,7 +1,7 @@ -openfl>=1.2.1 -numpy>=1.13.3 -scikit-learn>=0.24.1 matplotlib>=2.0.0 mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability +numpy>=1.13.3 +openfl>=1.2.1 +scikit-learn>=0.24.1 setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-tutorials/interactive_api/scikit_learn_linear_regression/workspace/requirements.txt b/openfl-tutorials/interactive_api/scikit_learn_linear_regression/workspace/requirements.txt index f1ad86dd90..40d18d92d5 100644 --- a/openfl-tutorials/interactive_api/scikit_learn_linear_regression/workspace/requirements.txt +++ b/openfl-tutorials/interactive_api/scikit_learn_linear_regression/workspace/requirements.txt @@ -1,7 +1,7 @@ -openfl>=1.2.1 -numpy>=1.13.3 -scikit-learn>=0.24.1 matplotlib>=2.0.0 mistune>=2.0.3 # not directly required, pinned by Snyk to avoid a vulnerability +numpy>=1.13.3 +openfl>=1.2.1 +scikit-learn>=0.24.1 setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/experimental/101_torch_cnn_mnist/requirements.txt b/openfl-workspace/experimental/101_torch_cnn_mnist/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/openfl-workspace/experimental/101_torch_cnn_mnist/requirements.txt +++ b/openfl-workspace/experimental/101_torch_cnn_mnist/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/experimental/102_aggregator_validation/requirements.txt b/openfl-workspace/experimental/102_aggregator_validation/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/openfl-workspace/experimental/102_aggregator_validation/requirements.txt +++ b/openfl-workspace/experimental/102_aggregator_validation/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/experimental/301_torch_cnn_mnist_watermarking/requirements.txt b/openfl-workspace/experimental/301_torch_cnn_mnist_watermarking/requirements.txt index a915fc1eaf..32969887d0 100644 --- a/openfl-workspace/experimental/301_torch_cnn_mnist_watermarking/requirements.txt +++ b/openfl-workspace/experimental/301_torch_cnn_mnist_watermarking/requirements.txt @@ -1,7 +1,7 @@ +imagen @ git+https://github.com/pyviz-topics/imagen.git@master +matplotlib +param==1.13.0 +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability -matplotlib -imagen @ git+https://github.com/pyviz-topics/imagen.git@master -param==1.13.0 diff --git a/openfl-workspace/experimental/501_pytorch_tinyimagenet_transfer_learning/requirements.txt b/openfl-workspace/experimental/501_pytorch_tinyimagenet_transfer_learning/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/openfl-workspace/experimental/501_pytorch_tinyimagenet_transfer_learning/requirements.txt +++ b/openfl-workspace/experimental/501_pytorch_tinyimagenet_transfer_learning/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/tf_2dunet/requirements.txt b/openfl-workspace/tf_2dunet/requirements.txt index f655f6c7d2..640dad7154 100644 --- a/openfl-workspace/tf_2dunet/requirements.txt +++ b/openfl-workspace/tf_2dunet/requirements.txt @@ -1,3 +1,3 @@ nibabel -tensorflow==2.13 setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability +tensorflow==2.13 diff --git a/openfl-workspace/tf_3dunet_brats/requirements.txt b/openfl-workspace/tf_3dunet_brats/requirements.txt index ed58705a66..35ae57088b 100644 --- a/openfl-workspace/tf_3dunet_brats/requirements.txt +++ b/openfl-workspace/tf_3dunet_brats/requirements.txt @@ -1,5 +1,5 @@ -tensorflow>=2 nibabel numpy setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability +tensorflow>=2 diff --git a/openfl-workspace/torch_cnn_histology/requirements.txt b/openfl-workspace/torch_cnn_histology/requirements.txt index 8e908c595d..58b9f15677 100644 --- a/openfl-workspace/torch_cnn_histology/requirements.txt +++ b/openfl-workspace/torch_cnn_histology/requirements.txt @@ -1,2 +1,2 @@ +torch==2.3.1 torchvision==0.18.1 -torch==2.3.1 \ No newline at end of file diff --git a/openfl-workspace/torch_cnn_histology_gramine_ready/requirements.txt b/openfl-workspace/torch_cnn_histology_gramine_ready/requirements.txt index 75593eb9c8..13bc80fd31 100644 --- a/openfl-workspace/torch_cnn_histology_gramine_ready/requirements.txt +++ b/openfl-workspace/torch_cnn_histology_gramine_ready/requirements.txt @@ -1,3 +1,3 @@ --index-url https://download.pytorch.org/whl/cpu torch==2.3.1 -torchvision==0.18.1 \ No newline at end of file +torchvision==0.18.1 diff --git a/openfl-workspace/torch_cnn_mnist/requirements.txt b/openfl-workspace/torch_cnn_mnist/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/openfl-workspace/torch_cnn_mnist/requirements.txt +++ b/openfl-workspace/torch_cnn_mnist/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/torch_cnn_mnist_eden_compression/requirements.txt b/openfl-workspace/torch_cnn_mnist_eden_compression/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/openfl-workspace/torch_cnn_mnist_eden_compression/requirements.txt +++ b/openfl-workspace/torch_cnn_mnist_eden_compression/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/torch_cnn_mnist_fed_eval/requirements.txt b/openfl-workspace/torch_cnn_mnist_fed_eval/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/openfl-workspace/torch_cnn_mnist_fed_eval/requirements.txt +++ b/openfl-workspace/torch_cnn_mnist_fed_eval/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/torch_cnn_mnist_straggler_check/requirements.txt b/openfl-workspace/torch_cnn_mnist_straggler_check/requirements.txt index 5db2ffa017..a85a139705 100644 --- a/openfl-workspace/torch_cnn_mnist_straggler_check/requirements.txt +++ b/openfl-workspace/torch_cnn_mnist_straggler_check/requirements.txt @@ -1,7 +1,7 @@ -torch==2.3.1 -torchvision==0.18.1 -tensorboard numpy>=1.22.2 # not directly required, pinned by Snyk to avoid a vulnerability rsa>=4.7 # not directly required, pinned by Snyk to avoid a vulnerability setuptools>=65.5.1 # not directly required, pinned by Snyk to avoid a vulnerability +tensorboard +torch==2.3.1 +torchvision==0.18.1 wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/torch_llm_horovod/requirements.txt b/openfl-workspace/torch_llm_horovod/requirements.txt index 193e1b598a..aa6b5f68e8 100644 --- a/openfl-workspace/torch_llm_horovod/requirements.txt +++ b/openfl-workspace/torch_llm_horovod/requirements.txt @@ -1,14 +1,14 @@ -torch -tensorboard -wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability -sentencepiece accelerate -jupyter -huggingface_hub -peft -transformers[torch] datasets evaluate -seqeval horovod -torchvision \ No newline at end of file +huggingface_hub +jupyter +peft +sentencepiece +seqeval +tensorboard +torch +torchvision +transformers[torch] +wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/openfl-workspace/torch_template/requirements.txt b/openfl-workspace/torch_template/requirements.txt index a1365f41c6..8530fda990 100644 --- a/openfl-workspace/torch_template/requirements.txt +++ b/openfl-workspace/torch_template/requirements.txt @@ -1,3 +1,3 @@ # Set your workspace's requirements here torch -torchvision \ No newline at end of file +torchvision diff --git a/openfl-workspace/torch_template/src/__init__.py b/openfl-workspace/torch_template/src/__init__.py index 4582b4f9aa..916f3a44b2 100644 --- a/openfl-workspace/torch_template/src/__init__.py +++ b/openfl-workspace/torch_template/src/__init__.py @@ -1,2 +1,2 @@ # Copyright (C) 2024 Intel Corporation -# SPDX-License-Identifier: Apache-2.0 \ No newline at end of file +# SPDX-License-Identifier: Apache-2.0 diff --git a/openfl-workspace/torch_template/src/dataloader.py b/openfl-workspace/torch_template/src/dataloader.py index 69c5a64722..302f4b0385 100644 --- a/openfl-workspace/torch_template/src/dataloader.py +++ b/openfl-workspace/torch_template/src/dataloader.py @@ -65,4 +65,4 @@ def load_dataset(data_path, **kwargs): return X_train, y_train, X_valid, y_valid -raise NotImplementedError("Use /src/dataloader.py template to create a custom dataloader. Then remove this line.") \ No newline at end of file +raise NotImplementedError("Use /src/dataloader.py template to create a custom dataloader. Then remove this line.") diff --git a/openfl-workspace/torch_template/src/taskrunner.py b/openfl-workspace/torch_template/src/taskrunner.py index aea0320b1d..8a7f24d4fc 100644 --- a/openfl-workspace/torch_template/src/taskrunner.py +++ b/openfl-workspace/torch_template/src/taskrunner.py @@ -105,4 +105,4 @@ def validate_( raise NotImplementedError( "Use /src/taskrunner.py template to create a custom Task Runner " "with your model definition and training/validation logic. Then remove this line." -) \ No newline at end of file +) diff --git a/openfl-workspace/torch_unet_kvasir/requirements.txt b/openfl-workspace/torch_unet_kvasir/requirements.txt index e9bd2a7b71..a08b005418 100644 --- a/openfl-workspace/torch_unet_kvasir/requirements.txt +++ b/openfl-workspace/torch_unet_kvasir/requirements.txt @@ -1,3 +1,3 @@ +scikit-image==0.24.0 torch==2.3.1 torchvision==0.18.1 -scikit-image==0.24.0 diff --git a/openfl-workspace/torch_unet_kvasir_gramine_ready/requirements.txt b/openfl-workspace/torch_unet_kvasir_gramine_ready/requirements.txt index bca8e7792b..f890ef2748 100644 --- a/openfl-workspace/torch_unet_kvasir_gramine_ready/requirements.txt +++ b/openfl-workspace/torch_unet_kvasir_gramine_ready/requirements.txt @@ -1,6 +1,6 @@ -scikit-image==0.24.0 -pillow==10.4.0 --extra-index-url https://download.pytorch.org/whl/cpu +pillow==10.4.0 +scikit-image==0.24.0 torch==2.3.1 -torchvision==0.18.1 \ No newline at end of file +torchvision==0.18.1 diff --git a/openfl/component/director/director.py b/openfl/component/director/director.py index eff4066a1c..f4ca3cc731 100644 --- a/openfl/component/director/director.py +++ b/openfl/component/director/director.py @@ -460,7 +460,6 @@ async def start_experiment_execution_loop(self): loop = asyncio.get_event_loop() while True: async with self.experiments_registry.get_next_experiment() as experiment: - # Review experiment block starts. if self.review_plan_callback: if not await experiment.review_experiment(self.review_plan_callback): diff --git a/openfl/experimental/component/aggregator/aggregator.py b/openfl/experimental/component/aggregator/aggregator.py index e8113eca93..40a94b5148 100644 --- a/openfl/experimental/component/aggregator/aggregator.py +++ b/openfl/experimental/component/aggregator/aggregator.py @@ -53,7 +53,6 @@ def __init__( log_metric_callback: Callable = None, **kwargs, ) -> None: - self.logger = getLogger(__name__) self.single_col_cert_common_name = single_col_cert_common_name @@ -222,7 +221,6 @@ def call_checkpoint(self, ctx: Any, f: Callable, stream_buffer: bytes = None) -> None """ if self.checkpoint: - # Check if arguments are pickled, if yes then unpickle if not isinstance(ctx, FLSpec): ctx = pickle.loads(ctx) diff --git a/openfl/experimental/component/collaborator/collaborator.py b/openfl/experimental/component/collaborator/collaborator.py index e181974652..0a41ea5fe4 100644 --- a/openfl/experimental/component/collaborator/collaborator.py +++ b/openfl/experimental/component/collaborator/collaborator.py @@ -39,7 +39,6 @@ def __init__( private_attributes: Dict = {}, **kwargs, ) -> None: - self.name = collaborator_name self.aggregator_uuid = aggregator_uuid self.federation_uuid = federation_uuid diff --git a/openfl/experimental/federated/plan/plan.py b/openfl/experimental/federated/plan/plan.py index 217260521f..b184ad12e7 100644 --- a/openfl/experimental/federated/plan/plan.py +++ b/openfl/experimental/federated/plan/plan.py @@ -42,7 +42,6 @@ def dump(yaml_path, config, freeze=False): """Dump the plan config to YAML file.""" class NoAliasDumper(SafeDumper): - def ignore_aliases(self, data): return True @@ -403,7 +402,6 @@ def get_flow(self): return self.flow_ def import_kwargs_modules(self, defaults): - def import_nested_settings(settings): for key, value in settings.items(): if isinstance(value, dict): diff --git a/openfl/experimental/interface/cli/aggregator.py b/openfl/experimental/interface/cli/aggregator.py index e72243ea67..707eacbabc 100644 --- a/openfl/experimental/interface/cli/aggregator.py +++ b/openfl/experimental/interface/cli/aggregator.py @@ -79,7 +79,6 @@ def start_(plan, authorized_cols, secure): + " in workspace." ) else: - with open("plan/data.yaml", "r") as f: data = yaml.load(f, Loader=SafeLoader) if data.get("aggregator", None) is None: @@ -218,7 +217,6 @@ def certify(fqdn, silent): else: echo("Make sure the two hashes above are the same.") if confirm("Do you want to sign this certificate?"): - echo(" Signing AGGREGATOR certificate") signed_agg_cert = sign_certificate(csr, signing_key, signing_crt.subject) write_crt(signed_agg_cert, crt_path_absolute_path) diff --git a/openfl/experimental/interface/cli/cli_helper.py b/openfl/experimental/interface/cli/cli_helper.py index f8f3ddab14..8cf992543e 100644 --- a/openfl/experimental/interface/cli/cli_helper.py +++ b/openfl/experimental/interface/cli/cli_helper.py @@ -36,7 +36,6 @@ def tree(path): echo(f"+ {path}") for path in sorted(path.rglob("*")): - depth = len(path.relative_to(path).parts) space = " " * depth @@ -108,7 +107,6 @@ def copytree( copy_function = shutil.copy2 def _copytree(): - if ignore is not None: ignored_names = ignore(os.fspath(src), [x.name for x in entries]) else: diff --git a/openfl/experimental/interface/cli/collaborator.py b/openfl/experimental/interface/cli/collaborator.py index d2d3fe27d6..2b0911b523 100644 --- a/openfl/experimental/interface/cli/collaborator.py +++ b/openfl/experimental/interface/cli/collaborator.py @@ -81,7 +81,6 @@ def start_(plan, collaborator_name, secure, data_config="plan/data.yaml"): f" {data_config} not found in workspace." ) else: - with open(data_config, "r") as f: data = yaml.load(f, Loader=SafeLoader) if data.get(collaborator_name, None) is None: @@ -145,7 +144,6 @@ def generate_cert_request(collaborator_name, silent, skip_package): write_key(client_private_key, CERT_DIR / "client" / f"{file_name}.key") if not skip_package: - archive_type = "zip" archive_name = f"col_{common_name}_to_agg_cert_request" archive_file_name = archive_name + "." + archive_type diff --git a/openfl/experimental/interface/cli/workspace.py b/openfl/experimental/interface/cli/workspace.py index 0e72106d80..21d5625f68 100644 --- a/openfl/experimental/interface/cli/workspace.py +++ b/openfl/experimental/interface/cli/workspace.py @@ -438,7 +438,6 @@ def _get_requirements_dict(txtfile): def _get_dir_hash(path): - hash_ = sha256() hash_.update(path.encode("utf-8")) hash_ = hash_.hexdigest() diff --git a/openfl/experimental/protocols/interceptors.py b/openfl/experimental/protocols/interceptors.py index a621897ebb..3549529da6 100644 --- a/openfl/experimental/protocols/interceptors.py +++ b/openfl/experimental/protocols/interceptors.py @@ -14,7 +14,6 @@ class _GenericClientInterceptor( grpc.StreamUnaryClientInterceptor, grpc.StreamStreamClientInterceptor, ): - def __init__(self, interceptor_function): self._fn = interceptor_function diff --git a/openfl/experimental/runtime/runtime.py b/openfl/experimental/runtime/runtime.py index 539c5be7e5..3c8dd49a75 100644 --- a/openfl/experimental/runtime/runtime.py +++ b/openfl/experimental/runtime/runtime.py @@ -11,7 +11,6 @@ class Runtime: - def __init__(self): """Initializes the Runtime object. diff --git a/openfl/experimental/transport/grpc/aggregator_client.py b/openfl/experimental/transport/grpc/aggregator_client.py index b6587badaa..effdb105ae 100644 --- a/openfl/experimental/transport/grpc/aggregator_client.py +++ b/openfl/experimental/transport/grpc/aggregator_client.py @@ -50,7 +50,6 @@ def _intercept_call(self, continuation, client_call_details, request_or_iterator response = continuation(client_call_details, request_or_iterator) if isinstance(response, grpc.RpcError): - # If status code is not in retryable status codes self.sleeping_policy.logger.info(f"Response code: {response.code()}") if self.status_for_retry and response.code() not in self.status_for_retry: @@ -70,7 +69,6 @@ def intercept_stream_unary(self, continuation, client_call_details, request_iter def _atomic_connection(func): - def wrapper(self, *args, **kwargs): self.reconnect() response = func(self, *args, **kwargs) @@ -81,7 +79,6 @@ def wrapper(self, *args, **kwargs): def _resend_data_on_reconnection(func): - def wrapper(self, *args, **kwargs): while True: try: diff --git a/openfl/experimental/transport/grpc/aggregator_server.py b/openfl/experimental/transport/grpc/aggregator_server.py index 89199adde5..5b6a18eb3c 100644 --- a/openfl/experimental/transport/grpc/aggregator_server.py +++ b/openfl/experimental/transport/grpc/aggregator_server.py @@ -192,13 +192,11 @@ def get_server(self): aggregator_pb2_grpc.add_AggregatorServicer_to_server(self, self.server) if not self.tls: - self.logger.warn("gRPC is running on insecure channel with TLS disabled.") port = self.server.add_insecure_port(self.uri) self.logger.info(f"Insecure port: {port}") else: - with open(self.private_key, "rb") as f: private_key_b = f.read() with open(self.certificate, "rb") as f: diff --git a/openfl/experimental/utilities/metaflow_utils.py b/openfl/experimental/utilities/metaflow_utils.py index 51c783298e..066429a41e 100644 --- a/openfl/experimental/utilities/metaflow_utils.py +++ b/openfl/experimental/utilities/metaflow_utils.py @@ -91,7 +91,6 @@ def __init__(self, name): @ray.remote class Counter: - def __init__(self): """Initializes the Counter with value set to 0.""" self.value = 0 diff --git a/openfl/federated/plan/plan.py b/openfl/federated/plan/plan.py index 552b460b6f..5f0575837d 100644 --- a/openfl/federated/plan/plan.py +++ b/openfl/federated/plan/plan.py @@ -80,7 +80,6 @@ def dump(yaml_path, config, freeze=False): """ class NoAliasDumper(SafeDumper): - def ignore_aliases(self, data): return True @@ -124,7 +123,6 @@ def parse( Plan: A Federated Learning plan object. """ try: - plan = Plan() plan.config = Plan.load(plan_config_path) # load plan configuration plan.name = plan_config_path.name @@ -132,7 +130,6 @@ def parse( # ensure 'settings' appears in each top-level section for section in plan.config.keys(): - if plan.config[section].get(SETTINGS) is None: plan.config[section][SETTINGS] = {} diff --git a/openfl/federated/task/task_runner.py b/openfl/federated/task/task_runner.py index 28fd23bb3f..ef6d83e4ea 100644 --- a/openfl/federated/task/task_runner.py +++ b/openfl/federated/task/task_runner.py @@ -127,7 +127,6 @@ def adapt_tasks(self): """ def task_binder(task_name, callable_task): - def collaborator_adapted_task(col_name, round_num, input_tensor_dict, **kwargs): task_contract = self.task_provider.task_contract[task_name] # Validation flag can be [False, '_local', '_agg'] diff --git a/openfl/interface/aggregator.py b/openfl/interface/aggregator.py index 4ad4f57df5..2d834f95f1 100644 --- a/openfl/interface/aggregator.py +++ b/openfl/interface/aggregator.py @@ -230,17 +230,14 @@ def certify(fqdn, silent): crt_path_absolute_path = Path(CERT_DIR / f"{cert_name}.crt").absolute() if silent: - echo(" Warning: manual check of certificate hashes is bypassed in silent mode.") echo(" Signing AGGREGATOR certificate") signed_agg_cert = sign_certificate(csr, signing_key, signing_crt.subject) write_crt(signed_agg_cert, crt_path_absolute_path) else: - echo("Make sure the two hashes above are the same.") if confirm("Do you want to sign this certificate?"): - echo(" Signing AGGREGATOR certificate") signed_agg_cert = sign_certificate(csr, signing_key, signing_crt.subject) write_crt(signed_agg_cert, crt_path_absolute_path) diff --git a/openfl/interface/cli.py b/openfl/interface/cli.py index d38fd5c37e..9d2b1c1b8d 100755 --- a/openfl/interface/cli.py +++ b/openfl/interface/cli.py @@ -311,7 +311,6 @@ def entry(): path.insert(0, str(work)) for module in root.glob("*.py"): # load command modules - package = module.parent module = module.name.split(".")[0] diff --git a/openfl/interface/cli_helper.py b/openfl/interface/cli_helper.py index d78fce5d65..a326527158 100644 --- a/openfl/interface/cli_helper.py +++ b/openfl/interface/cli_helper.py @@ -45,7 +45,6 @@ def tree(path): echo(f"+ {path}") for path in sorted(path.rglob("*")): - depth = len(path.relative_to(path).parts) space = " " * depth @@ -139,7 +138,6 @@ def copytree( copy_function = shutil.copy2 def _copytree(): - if ignore is not None: ignored_names = ignore(os.fspath(src), [x.name for x in entries]) else: diff --git a/openfl/interface/collaborator.py b/openfl/interface/collaborator.py index 406ff347c0..9276375373 100644 --- a/openfl/interface/collaborator.py +++ b/openfl/interface/collaborator.py @@ -241,7 +241,6 @@ def generate_cert_request(collaborator_name, silent, skip_package): write_key(client_private_key, CERT_DIR / "client" / f"{file_name}.key") if not skip_package: - archive_type = "zip" archive_name = f"col_{common_name}_to_agg_cert_request" archive_file_name = archive_name + "." + archive_type @@ -305,7 +304,6 @@ def register_collaborator(file_name): doc["collaborators"] = [] # Create empty list if col_name in doc["collaborators"]: - echo( "\nCollaborator " + style(f"{col_name}", fg="green") @@ -314,7 +312,6 @@ def register_collaborator(file_name): ) else: - doc["collaborators"].append(col_name) with open(cols_file, "w", encoding="utf-8") as f: dump(doc, f) @@ -438,7 +435,6 @@ def certify(collaborator_name, silent, request_pkg=None, import_=False): ) if silent: - echo(" Signing COLLABORATOR certificate") echo(" Warning: manual check of certificate hashes is bypassed in silent mode.") signed_col_cert = sign_certificate(csr, signing_key, signing_crt.subject) @@ -446,10 +442,8 @@ def certify(collaborator_name, silent, request_pkg=None, import_=False): register_collaborator(CERT_DIR / "client" / f"{file_name}.crt") else: - echo("Make sure the two hashes above are the same.") if confirm("Do you want to sign this certificate?"): - echo(" Signing COLLABORATOR certificate") signed_col_cert = sign_certificate(csr, signing_key, signing_crt.subject) write_crt(signed_col_cert, f"{cert_name}.crt") diff --git a/openfl/interface/plan.py b/openfl/interface/plan.py index f7d65eb84a..f4c91faed0 100644 --- a/openfl/interface/plan.py +++ b/openfl/interface/plan.py @@ -275,7 +275,6 @@ def switch_plan(name): plan_file = f"plan/plans/{name}/plan.yaml" if isfile(plan_file): - echo(f"Switch plan to {name}") # Copy the new plan.yaml file to the top directory diff --git a/openfl/native/fastestimator.py b/openfl/native/fastestimator.py index 5c460d0855..b794d30387 100644 --- a/openfl/native/fastestimator.py +++ b/openfl/native/fastestimator.py @@ -151,7 +151,6 @@ def fit(self): model = None for round_num in range(self.rounds): for col in plan.authorized_cols: - collaborator = collaborators[col] if round_num != 0: diff --git a/openfl/pipelines/eden_pipeline.py b/openfl/pipelines/eden_pipeline.py index ba8a7d84c1..61c51cd8d9 100644 --- a/openfl/pipelines/eden_pipeline.py +++ b/openfl/pipelines/eden_pipeline.py @@ -515,7 +515,6 @@ def quantize(self, vec): vec_norm = torch.norm(vec, 2) if vec_norm > 0: - normalized = vec * (vec.numel() ** 0.5) / vec_norm bins = torch.bucketize(normalized, self.boundaries[self.nbits]) scale = vec_norm**2 / torch.dot(torch.take(self.centroids[self.nbits], bins), vec) @@ -540,7 +539,6 @@ def compress_slice(self, vec, seed): dim = vec.numel() if not dim & (dim - 1) == 0 or dim < 8: - padded_dim = max(int(2 ** (np.ceil(np.log2(dim)))), 8) padded_vec = torch.zeros(padded_dim, device=self.device) padded_vec[:dim] = vec @@ -673,7 +671,6 @@ def to_bits(self, int_bool_vec): """ def to_bits_h(ibv): - n = ibv.numel() ibv = ibv.view(n // 8, 8).int() @@ -705,7 +702,6 @@ def from_bits(self, bit_vec): """ def from_bits_h(bv): - n = bv.numel() iv = torch.zeros((8, n)).to(self.device) @@ -791,7 +787,6 @@ def forward(self, data, **kwargs): return_values = int_array.astype(np.uint8).tobytes(), metadata else: - no_comp_data, metadata = self.no_comp.forward(data) return_values = no_comp_data, metadata diff --git a/openfl/plugins/frameworks_adapters/keras_adapter.py b/openfl/plugins/frameworks_adapters/keras_adapter.py index 0251071dad..46373c629b 100644 --- a/openfl/plugins/frameworks_adapters/keras_adapter.py +++ b/openfl/plugins/frameworks_adapters/keras_adapter.py @@ -43,7 +43,6 @@ def unpack(model, training_config, weights): # Hotfix function, not required for TF versions above 2.7.1. # https://github.com/keras-team/keras/pull/14748. def make_keras_picklable(): - def __reduce__(self): # NOQA:N807 model_metadata = saving_utils.model_metadata(self) training_config = model_metadata.get("training_config", None) diff --git a/openfl/protocols/interceptors.py b/openfl/protocols/interceptors.py index a621897ebb..3549529da6 100644 --- a/openfl/protocols/interceptors.py +++ b/openfl/protocols/interceptors.py @@ -14,7 +14,6 @@ class _GenericClientInterceptor( grpc.StreamUnaryClientInterceptor, grpc.StreamStreamClientInterceptor, ): - def __init__(self, interceptor_function): self._fn = interceptor_function diff --git a/openfl/transport/grpc/aggregator_client.py b/openfl/transport/grpc/aggregator_client.py index 5700dbf3c4..14c324e8a3 100644 --- a/openfl/transport/grpc/aggregator_client.py +++ b/openfl/transport/grpc/aggregator_client.py @@ -94,7 +94,6 @@ def _intercept_call(self, continuation, client_call_details, request_or_iterator response = continuation(client_call_details, request_or_iterator) if isinstance(response, grpc.RpcError): - # If status code is not in retryable status codes self.sleeping_policy.logger.info("Response code: %s", response.code()) if self.status_for_retry and response.code() not in self.status_for_retry: @@ -135,7 +134,6 @@ def intercept_stream_unary(self, continuation, client_call_details, request_iter def _atomic_connection(func): - def wrapper(self, *args, **kwargs): self.reconnect() response = func(self, *args, **kwargs) @@ -146,7 +144,6 @@ def wrapper(self, *args, **kwargs): def _resend_data_on_reconnection(func): - def wrapper(self, *args, **kwargs): while True: try: diff --git a/openfl/transport/grpc/aggregator_server.py b/openfl/transport/grpc/aggregator_server.py index db952db38c..b7c54813af 100644 --- a/openfl/transport/grpc/aggregator_server.py +++ b/openfl/transport/grpc/aggregator_server.py @@ -307,13 +307,11 @@ def get_server(self): aggregator_pb2_grpc.add_AggregatorServicer_to_server(self, self.server) if not self.tls: - self.logger.warn("gRPC is running on insecure channel with TLS disabled.") port = self.server.add_insecure_port(self.uri) self.logger.info("Insecure port: %s", port) else: - with open(self.private_key, "rb") as f: private_key_b = f.read() with open(self.certificate, "rb") as f: diff --git a/shell/format.sh b/shell/format.sh index 6637a4315c..5d8f2c1547 100755 --- a/shell/format.sh +++ b/shell/format.sh @@ -3,6 +3,9 @@ set -Eeuo pipefail base_dir=$(dirname $(dirname $0)) +# Run the pre-commit checks +pre-commit run --all-files + isort --sp "${base_dir}/pyproject.toml" openfl black --config "${base_dir}/pyproject.toml" openfl diff --git a/shell/lint.sh b/shell/lint.sh index 295a7e6241..f3cee9c4a1 100755 --- a/shell/lint.sh +++ b/shell/lint.sh @@ -3,6 +3,9 @@ set -Eeuo pipefail base_dir=$(dirname $(dirname $0)) +# Run the pre-commit checks +pre-commit run --all-files + isort --sp "${base_dir}/pyproject.toml" --check openfl black --config "${base_dir}/pyproject.toml" --check openfl diff --git a/test-requirements.txt b/test-requirements.txt index 1b09a3f332..80ed75cde5 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,3 +1,3 @@ pytest==8.3.3 +pytest-asyncio==0.24.0 pytest-mock==3.14.0 -pytest-asyncio==0.24.0 \ No newline at end of file diff --git a/tests/github/experimental/workspace/test_experimental_agg_based_workflow.py b/tests/github/experimental/workspace/test_experimental_agg_based_workflow.py index 5653b143f6..a92ac36a9b 100644 --- a/tests/github/experimental/workspace/test_experimental_agg_based_workflow.py +++ b/tests/github/experimental/workspace/test_experimental_agg_based_workflow.py @@ -3,7 +3,6 @@ import os import time -import socket import argparse from pathlib import Path from subprocess import check_call diff --git a/tests/github/experimental/workspace/testcase_datastore_cli/requirements.txt b/tests/github/experimental/workspace/testcase_datastore_cli/requirements.txt index 046073d366..0cb16c0bfc 100644 --- a/tests/github/experimental/workspace/testcase_datastore_cli/requirements.txt +++ b/tests/github/experimental/workspace/testcase_datastore_cli/requirements.txt @@ -1,2 +1,2 @@ -wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability torchvision +wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_internalloop/requirements.txt b/tests/github/experimental/workspace/testcase_internalloop/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_internalloop/requirements.txt +++ b/tests/github/experimental/workspace/testcase_internalloop/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_private_attributes/requirements.txt b/tests/github/experimental/workspace/testcase_private_attributes/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_private_attributes/requirements.txt +++ b/tests/github/experimental/workspace/testcase_private_attributes/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_private_attributes_initialization_with_both_options/requirements.txt b/tests/github/experimental/workspace/testcase_private_attributes_initialization_with_both_options/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_private_attributes_initialization_with_both_options/requirements.txt +++ b/tests/github/experimental/workspace/testcase_private_attributes_initialization_with_both_options/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_private_attributes_initialization_without_callable/requirements.txt b/tests/github/experimental/workspace/testcase_private_attributes_initialization_without_callable/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_private_attributes_initialization_without_callable/requirements.txt +++ b/tests/github/experimental/workspace/testcase_private_attributes_initialization_without_callable/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_reference/requirements.txt b/tests/github/experimental/workspace/testcase_reference/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_reference/requirements.txt +++ b/tests/github/experimental/workspace/testcase_reference/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_reference_with_include_exclude/requirements.txt b/tests/github/experimental/workspace/testcase_reference_with_include_exclude/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_reference_with_include_exclude/requirements.txt +++ b/tests/github/experimental/workspace/testcase_reference_with_include_exclude/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/experimental/workspace/testcase_validate_particpant_names/requirements.txt b/tests/github/experimental/workspace/testcase_validate_particpant_names/requirements.txt index f93aef46e7..8b084abb8f 100644 --- a/tests/github/experimental/workspace/testcase_validate_particpant_names/requirements.txt +++ b/tests/github/experimental/workspace/testcase_validate_particpant_names/requirements.txt @@ -1,4 +1,4 @@ +tensorboard torch==2.3.1 torchvision==0.18.1 -tensorboard wheel>=0.38.0 # not directly required, pinned by Snyk to avoid a vulnerability diff --git a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/dataset.py b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/dataset.py index 61cb184b6f..80fec58638 100644 --- a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/dataset.py +++ b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/dataset.py @@ -107,4 +107,3 @@ def get_valid_data_size(self): Information for aggregation """ return len(self.valid_set) - diff --git a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/envoy/sd_requirements.txt b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/envoy/sd_requirements.txt index 50acd55c94..5e3549a040 100644 --- a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/envoy/sd_requirements.txt +++ b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/envoy/sd_requirements.txt @@ -1,3 +1,3 @@ numpy pillow -scikit-image \ No newline at end of file +scikit-image diff --git a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/experiment.py b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/experiment.py index b6b791bfa7..4b8e0b48fd 100644 --- a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/experiment.py +++ b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/experiment.py @@ -25,8 +25,6 @@ def run(): tls=False ) - shard_registry = federation.get_shard_registry() - dummy_shard_desc = federation.get_dummy_shard_descriptor(size=10) dummy_shard_dataset = dummy_shard_desc.get_dataset('') sample, target = dummy_shard_dataset[0] diff --git a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/tasks.py b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/tasks.py index d788c531ff..577a5156af 100644 --- a/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/tasks.py +++ b/tests/github/interactive_api_director/experiments/pytorch_kvasir_unet/tasks.py @@ -64,4 +64,4 @@ def validate(unet_model, val_loader, device): val = soft_dice_coef(output, target) val_score += val.sum().cpu().numpy() - return {'dice_coef': val_score / total_samples, } \ No newline at end of file + return {'dice_coef': val_score / total_samples, } diff --git a/tests/github/interactive_api_director/experiments/tensorflow_mnist/dataset.py b/tests/github/interactive_api_director/experiments/tensorflow_mnist/dataset.py index ae4dd71bed..94456ed917 100644 --- a/tests/github/interactive_api_director/experiments/tensorflow_mnist/dataset.py +++ b/tests/github/interactive_api_director/experiments/tensorflow_mnist/dataset.py @@ -13,7 +13,7 @@ def __init__(self, train_bs, valid_bs, **kwargs): @property def shard_descriptor(self): return self._shard_descriptor - + @shard_descriptor.setter def shard_descriptor(self, shard_descriptor): """ diff --git a/tests/github/interactive_api_director/experiments/tensorflow_mnist/experiment.py b/tests/github/interactive_api_director/experiments/tensorflow_mnist/experiment.py index 655d62c917..ce20e434cc 100644 --- a/tests/github/interactive_api_director/experiments/tensorflow_mnist/experiment.py +++ b/tests/github/interactive_api_director/experiments/tensorflow_mnist/experiment.py @@ -1,4 +1,3 @@ -import time import tensorflow as tf # Create a federation from openfl.interface.interactive_api.federation import Federation @@ -10,14 +9,13 @@ from tests.github.interactive_api_director.experiments.tensorflow_mnist.settings import train_acc_metric from tests.github.interactive_api_director.experiments.tensorflow_mnist.settings import val_acc_metric from tests.github.interactive_api_director.experiments.tensorflow_mnist.envoy.shard_descriptor import MNISTShardDescriptor -from copy import deepcopy def run(): # please use the same identificator that was used in signed certificate client_id = 'frontend' - # 1) Run with API layer - Director mTLS + # 1) Run with API layer - Director mTLS # If the user wants to enable mTLS their must provide CA root chain, and signed key pair to the federation interface # cert_chain = 'cert/root_ca.crt' # API_certificate = 'cert/frontend.crt' @@ -54,7 +52,7 @@ def function_defined_in_notebook(some_parameter): TI = TaskInterface() # Task interface currently supports only standalone functions. @TI.register_fl_task(model='model', data_loader='train_dataset', - device='device', optimizer='optimizer') + device='device', optimizer='optimizer') def train(model, train_dataset, optimizer, device, loss_fn=loss_fn, warmup=False): # Iterate over the batches of the dataset. @@ -88,7 +86,7 @@ def train(model, train_dataset, optimizer, device, loss_fn=loss_fn, warmup=False return {'train_acc': train_acc} - @TI.register_fl_task(model='model', data_loader='val_dataset', device='device') + @TI.register_fl_task(model='model', data_loader='val_dataset', device='device') def validate(model, val_dataset, device): # Run a validation loop at the end of each epoch. for x_batch_val, y_batch_val in val_dataset: @@ -98,7 +96,7 @@ def validate(model, val_dataset, device): val_acc = val_acc_metric.result() val_acc_metric.reset_states() print("Validation acc: %.4f" % (float(val_acc),)) - + return {'validation_accuracy': val_acc,} # Save the initial model state train(model,fed_dataset.get_train_loader(), optimizer, 'cpu', warmup=True) @@ -119,7 +117,7 @@ def validate(model, val_dataset, device): # If I use autoreload I got a pickling error # The following command zips the workspace and python requirements to be transfered to collaborator nodes - fl_experiment.start(model_provider=MI, + fl_experiment.start(model_provider=MI, task_keeper=TI, data_loader=fed_dataset, rounds_to_train=2, diff --git a/tests/github/pki_insecure_client.py b/tests/github/pki_insecure_client.py index 10d80151b0..6246614f39 100644 --- a/tests/github/pki_insecure_client.py +++ b/tests/github/pki_insecure_client.py @@ -2,7 +2,6 @@ # SPDX-License-Identifier: Apache-2.0 from pathlib import Path import time -import logging import sys import shutil import subprocess diff --git a/tests/github/pki_wrong_cn.py b/tests/github/pki_wrong_cn.py index 7ee9e3eb96..0e6eeff541 100644 --- a/tests/github/pki_wrong_cn.py +++ b/tests/github/pki_wrong_cn.py @@ -4,7 +4,6 @@ import subprocess import os import time -import socket from multiprocessing import Process import sys import importlib diff --git a/tests/github/test_double_ws_export.py b/tests/github/test_double_ws_export.py index ac6640db61..da15a97d9f 100644 --- a/tests/github/test_double_ws_export.py +++ b/tests/github/test_double_ws_export.py @@ -3,7 +3,6 @@ import os import time -import socket import argparse from pathlib import Path import shutil diff --git a/tests/github/test_gandlf.py b/tests/github/test_gandlf.py index 5a30237671..e989b39e81 100644 --- a/tests/github/test_gandlf.py +++ b/tests/github/test_gandlf.py @@ -3,7 +3,6 @@ import os import time -import socket import argparse from pathlib import Path import re diff --git a/tests/github/test_hello_federation.py b/tests/github/test_hello_federation.py index d97dd9a79d..7e9e676fbe 100644 --- a/tests/github/test_hello_federation.py +++ b/tests/github/test_hello_federation.py @@ -3,7 +3,6 @@ import os import time -import socket import argparse from pathlib import Path from subprocess import check_call diff --git a/tests/openfl/interface/test_aggregator_api.py b/tests/openfl/interface/test_aggregator_api.py index 61757d4161..14572cf8ab 100644 --- a/tests/openfl/interface/test_aggregator_api.py +++ b/tests/openfl/interface/test_aggregator_api.py @@ -70,10 +70,10 @@ def test_aggregator_find_certificate_name(): # NOTE: This test is disabled because of cryptic behaviour on calling # _certify(). Previous version of _certify() had imports defined within # the function, which allowed theses tests to pass, whereas the goal of the -# @mock.patch here seems to be to make them dummy. Usefulness of this test is +# @mock.patch here seems to be to make them dummy. Usefulness of this test is # doubtful. Now that the imports are moved to the top level (a.k.a out of # _certify()) this test fails. -# In addition, using dummy return types for read/write key/csr seems to +# In addition, using dummy return types for read/write key/csr seems to # obviate the need for even testing _certify(). @pytest.mark.skip() @mock.patch('openfl.cryptography.io.write_crt')