Package Search Help

You can use boolean logic (e.g. AND/OR/NOT) for complex search queries. For more help and examples, see the search documentation.

Search by package name:
my-package (implicit)
name:my-package (explicit)

Search by package filename:
filename:my-package.ext 

Search by package tag:
tag:latest 

Search by package version:
version:1.0.0  prerelease:true (prereleases)
prerelease:false (no prereleases)

Search by package architecture:
architecture:x86_64 

Search by package distribution:
distribution:el 

Search by package license:
license:MIT 

Search by package format:
format:deb 

Search by package status:
status:in_progress 

Search by package file checksum:
checksum:5afba 

Search by package security status:
severity:critical 

Search by package vulnerabilities:
vulnerabilities:>1 
vulnerabilities:<1000 

Search by # of package downloads:
downloads:>8 
downloads:<100 

Search by package type:
type:binary 
type:source 

Search by package size (bytes):
size:>50000 
size:<10000 

Search by dependency name/version:
dependency:log4j 
dependency:log4j=1.0.0 
dependency:log4j>1.0.0 

Search by uploaded date:
uploaded:>"1 day ago" 
uploaded:<"August 14, 2022 EST" 

Search by entitlement token (identifier):
entitlement:3lKPVJPosCsY 

Search by policy violation:
policy_violated:true
deny_policy_violated:true
license_policy_violated:true
vulnerability_policy_violated:true

Search by repository:
repository:repo-name

Search by last download date:
last_downloaded:<"30 days ago" 
last_downloaded:>"August 14, 2022 EST" 

Search queries for all Debian-specific (and related) package types

Search by component:
deb_component:unstable

Search queries for all Maven-specific (and related) package types

Search by group ID:
maven_group_id:org.apache

Search queries for all Docker-specific (and related) package types

Search by image digest:
docker_image_digest:sha256:7c5..6d4
(full hashref only)

Search by layer digest:
docker_layer_digest:sha256:4c4..ae4
(full hashref only)

Search queries for all Generic-specific package types

Search by file path:
generic_filepath:path/to/file.txt

Search by directory:
generic_directory:path/to

Field type modifiers (depending on the type, you can influence behaviour)

For all queries, you can use:
~foo for negation

For string queries, you can use:
^foo to anchor to start of term
foo$ to anchor to end of term
foo*bar for fuzzy matching

For number/date or version queries, you can use:
>foo for values greater than
>=foo for values greater / equal
<foo for values less than
<=foo for values less / equal

Need a secure and centralised artifact repository to deliver Alpine, Cargo, CocoaPods, Composer, Conan, Conda, CRAN, Dart, Debian, Docker, Generic, Go, Helm, Hex, HuggingFace, LuaRocks, Maven, MCP, npm, NuGet, P2, Python, RedHat, Ruby, Swift, Terraform, Vagrant, VSX, Raw & More packages?

Cloudsmith is the new standard in Package / Artifact Management and Software Distribution.

With support for all major package formats, you can trust us to manage your software supply chain.

Start My Free Trial

Python logo branchkey  2.5.3

One-liner (summary)

Client application to interface with the BranchKey system

Description

# BranchKey Python Client Application ![BK_logo](https://branchkey.com/assets/images/logo.png) This application runs against the BranchKey backend aggregation service for Federated Learning. It provides a Python interface to login/logout a client, upload files to the system for aggregation, and download aggregated output files. # Install - `pip install branchkey` # Build Instructions - To build the dependencies: - `make setup`, or - `pip install -r requirements.txt` - To run the tests: `make test` - `make test`, or - python3 -m unittest -v # Usage instructions - To use a client: ```python import json from branchkey.client import Client credentials = {"leaf_name": "leaf-1", "leaf_id": "46780841-9787-41e6-ac14-e3ee160e158a", "leaf_session_token": "46780841-9787-41e6-ac14-e3ee160e158a", "performance_analyser_username": "hello", "performance_analyser_password": "world", "response_host":"response.branchkey.com"} host = "http://api.branchkey.com" # initialise the client # it implicitly authenticates the leaf_session # and fetches the run_details of the parent branch c = Client(credentials,host) # upload the file to the system c.file_upload("./file/path.npy") # Download a file with the file_id value # same as the one received from the consumer # It downloads the files in the ./aggregated_files directory if not c.queue.empty(): aggregation_id = c.queue.get(block=False) c.file_download(aggregation_id) # To push performance analysis metrics for this aggregation: # mode can be test, train or non-federated data = json.dumps({"key1":"val1","key2":"val2"}) mode = "test" c.send_performance_metrics(aggregation_id, data, mode) ``` ## File format Weights file in a numpy `.npy` format: ```python with open("./test.npy", "wb") as f: np.save(f, parameter_array) [num_samples, [n_d parameter matrix]] ``` ``` num_samples - the number of samples that contributed to this update n_d parameter matrix - parameters ``` ### Required file format The required numpy arrays after exports ```python [1329, list([array([[[[ 1.71775490e-01, [[[ 8.74867663e-02, 5.19692302e-02, -1.64664671e-01,, -2.23452481e-03, 1.11475676e-01],, [-1.75505821e-02, -1... ``` ```python (1329, [array([[[[ 1.71775490e-01, 3.02851666e-02, 2.90171858e-02, -4.27578250e-03, 1.14474617e-01], [-8.07138346e-03, 1.44909814e-01, -5.36724664e-02, -3.51673253e-02, -1.82426855e-01], [ 6.75795972e-02, -1.72839850e-01, -7.25025982e-02, -1.59504730e-02, 1.60634145e-01], [ 6.62277341e-02, -2.26575769e-02, -1.65369093e-01, -8.67117420e-02, 1.80021569e-01], [-6.11407161e-02, -1.59245610e-01, 1.45820528e-01, -5.40512279e-02, -5.19061387e-02]]], .... [-1.44068539e-01, 6.15987852e-02, 1.83321223e-01, -1.79076958e-02, -1.53445438e-01], [-7.76787996e-02, 7.64556080e-02, 9.43044946e-02, 1.63337544e-01, -1.69042274e-01], [-8.55994076e-02, -1.23661250e-01, 1.48442864e-01, -1.35983482e-01, 2.05254350e-02]]]], dtype=float32), array([ 0.13065006, 0.12797254, -0.12818147, -0.09621437, 0.04100017, -0.07248228, 0.02753541, 0.00476395, -0.11270998, 0.11353076, -0.0167569 , 0.12654744, -0.05019006, -0.07281244, 0.03892357, -0.09698197, -0.06845284, -0.04604543, -0.01372138, -0.052395 , 0.04833373, 0.16228785, 0.09982517, 0.19556762, 0.10631064, 0.02496212, -0.14297573, -0.10442089, 0.01970248, -0.1684099 , -0.05076171, 0.19325127], dtype=float32), array([[[[-3.42470817e-02, 8.76816106e-04, -2.13724039e-02, -2.62880027e-02, -1.86583996e-02], [ 2.56936941e-02, -1.97169576e-02, -3.45735364e-02, -4.32738848e-03, -1.22306980e-02], [ 8.36322457e-03, 3.26042138e-02, -1.50063485e-02, -1.85401291e-02, 2.39207298e-02], [-1.15280924e-02, -3.47947963e-02, 2.17274204e-02, 1.80862695e-02, 2.19682772e-02], ... etc ```

Size

7.4 KB

Downloads

5

Status  Completed
Checksum (MD5) e1d61c5c0c033c273d236f6f555b8999
Checksum (SHA-1) d26d85e107c09ed22f14e60a2c0880310b7fb766
Checksum (SHA-256) fa3f5891bf104a2e84e656da4a106e3a27520d96efb9c2dd6b98004e5305818c
Checksum (SHA-512) ec3274b5bedb027873f7433993000bf164283274e8eb0d15d6cab2b23ce53e8a0a…
GPG Signature
GPG Fingerprint 6811684bac0b8895434e97bdd4391b8fb999e537
Storage Region  Dublin, Ireland
Type  Binary (contains binaries and binary artifacts)
Uploaded At 4 months, 3 weeks ago
Uploaded By Fetched by Cloudsmith
Slug Id branchkey-253-py3-none-anywhl-guwo
Unique Id OS63VnrQ4xkM76St
Version (Raw) 2.5.3
Version (Parsed)
  • Major: 2
  • Minor: 5
  • Patch: 3
  • Type: SemVer (Compat)
  extended metadata
Author BranchKey <info@branchkey.com>
Classifiers License :: OSI Approved :: MIT License | Operating System :: OS Independent | Programming Language :: Python :: 3
Homepage URL https://branchkey.com
Metadata Version 2.1
Project Urls Homepage, https://branchkey.com | Repository, https://gitlab.com/branchkey/client_application
Py Filetype bdist_wheel
Py Version py3
Requires Dist numpy | pika | requests | responses
Requires Python >=3.6
pkg branchkey-2.5.3-py3-none-any.whl 5
7.4 KB
md5 sha1 sha256 sha512
Package Contents (branchkey-2.5.3-py3-none-any.whl)
Loading...

This package has 11 files/directories.

 Newer Python logo
branchkey
 2.6.2
5 Fetched by Cloudsmith
 Newer Python logo
branchkey
 2.6.1
5 Fetched by Cloudsmith
 Newer Python logo
branchkey
 2.6.0
5 Fetched by Cloudsmith
 Newer Python logo
branchkey
 2.5.6
5 Fetched by Cloudsmith
 Newer Python logo
branchkey
 2.5.5
5 Fetched by Cloudsmith
 Newer Python logo
branchkey
 2.5.4
5 Fetched by Cloudsmith
  Python logo
branchkey
 2.5.3
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.5.2
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.5.1
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.5.0
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.4.2
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.4.1
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.4.0
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.3.0
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.2.3
4 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.2.2
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.2.1
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.2.0
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.1.4
5 Fetched by Cloudsmith
 Older Python logo
branchkey
 2.1.3
5 Fetched by Cloudsmith

Last scanned

4 months, 3 weeks ago

Scan result

Clean

Vulnerability count

0

Max. severity

Unknown

You can embed a badge in another website that shows this or the latest version of this package.

To embed the badge for this specific package version, use the following:

[![This version of 'branchkey' @ Cloudsmith](https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true)](https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/)
|This version of 'branchkey' @ Cloudsmith|
.. |This version of 'branchkey' @ Cloudsmith| image:: https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true
   :target: https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/
image::https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true[link="https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/",title="This version of 'branchkey' @ Cloudsmith"]
<a href="https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/"><img src="https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/2.5.3/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true" alt="This version of 'branchkey' @ Cloudsmith" /></a>

rendered as: This version of 'branchkey' @ Cloudsmith

To embed the badge for the latest package version, use the following:

[![Latest version of 'branchkey' @ Cloudsmith](https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true&show_latest=true)](https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/)
|Latest version of 'branchkey' @ Cloudsmith|
.. |Latest version of 'branchkey' @ Cloudsmith| image:: https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true&show_latest=true
   :target: https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/
image::https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true&show_latest=true[link="https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/",title="Latest version of 'branchkey' @ Cloudsmith"]
<a href="https://cloudsmith.io/~demo-docs/repos/awesome-repo/packages/detail/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/"><img src="https://api.cloudsmith.com/v1/badges/version/demo-docs/awesome-repo/python/branchkey/latest/a=noarch;xf=bdist_wheel;xn=branchkey;xv=py3/?render=true&show_latest=true" alt="Latest version of 'branchkey' @ Cloudsmith" /></a>

rendered as: Latest version of 'branchkey' @ Cloudsmith

These instructions assume you have setup the repository first (or read it).

To install/use branchkey @ version 2.5.3 ...

pip install 'branchkey==2.5.3'

You can also install the latest version of this package:

pip install --upgrade 'branchkey'

If necessary, you can specify the repository directly:

pip install \
  --index-url=https://dl.cloudsmith.io/public/demo-docs/awesome-repo/python/simple/ \
  branchkey==2.5.3

If you've got a project requirements.txt file, you can specify this as a dependency:

--index-url=https://dl.cloudsmith.io/public/demo-docs/awesome-repo/python/simple/
branchkey==2.5.3

In addition, you can use this repository as an extra index url. However, please read our documentation on this parameter before using it. For example in a requirements.txt file:

--extra-index-url=https://dl.cloudsmith.io/public/demo-docs/awesome-repo/python/simple/
branchkey==2.5.3
Warning: We highly recommend using pip (or similar) rather than installing directly.
Top