Skip to main content

# tensorflowjs: The Python Package for TensorFlow.js

The tensorflowjs pip package contains libraries and tools for [TensorFlow.js](https://js.tensorflow.org).

Use following command to install the library with support of interactive CLI: `bash pip install tensorflowjs[wizard] `

Then, run the following to see a list of CLI options

`bash tensorflowjs_converter --help `

or, use the wizard

`bash tensorflowjs_wizard `

Alternatively, run the converter via its Bazel target. This must be run from withing the tfjs repo:

`bash yarn bazel run //tfjs-converter/python/tensorflowjs/converters:converter -- --help `

## Development

The python tests are run with Bazel.

`bash yarn bazel test //tfjs-converter/python/... `

Alternatively, run yarn run-python-tests to run the above command.

To debug a specific test case, use the –test_filter option. For example,

`bash yarn bazel test //tfjs-converter/python/tensorflowjs/converters:tf_saved_model_conversion_v2_test --test_filter=ConvertTest.test_convert_saved_model_v1 `

Interactive debugging with breakpoints is supported by debugpy in VSCode. To enable debugging, put this code at the top of the test file you want to debug.

`python import debugpy debugpy.listen(('localhost', 5724)) print("Waiting for debugger to connect. See tfjs-converter python README") debugpy.wait_for_client() `

You may also need to add the following dependency to the test target in the Bazel BUILD file if it’s not already present. `starlark "//tfjs-converter/python/tensorflowjs:expect_debugpy_installed" `

Then, run the test with bazel run –config=debugpy and connect the VSCode debugger by selecting the Python: Attach (Converter) option.

Metadata

Release files for tensorflowjs 4.22.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for tensorflowjs 4.22.0
File Interpreter ABI Platform Actions
tensorflowjs-4.22.0-py3-none-any.whl Python 3 none any Details for tensorflowjs-4.22.0-py3-none-any.whl

Release files / tensorflowjs-4.22.0-py3-none-any.whl

Download URL tensorflowjs-4.22.0-py3-none-any.whl
Size 89.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bd4deb1e7feab538ee7f2625fe85446742bb4765bebab345b534688ab41e3e1c
BLAKE2b-256 checksum
How to use checksums
a240c363bdb7ef69b27c941c622b1f6e12eba5e3563abde737690fd1a13969ba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.11.9

Security for tensorflowjs 4.22.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

4.22.0 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page