{"id":9048,"library":"ipydatawidgets","title":"ipydatawidgets","description":"ipydatawidgets is a Python library that provides a set of interactive HTML widgets for Jupyter notebooks, designed to facilitate the reuse and efficient transmission of large datasets. Its primary purpose is to offer a standardized way to move array data between the Python kernel and the frontend, enabling multiple widgets to share the same data with a single network synchronization. The current version is 4.3.5, with an infrequent release cadence, the last PyPI release being in June 2023.","status":"active","version":"4.3.5","language":"en","source_language":"en","source_url":"https://github.com/vidartf/ipydatawidgets","tags":["jupyter","widgets","data","ipywidgets","numpy"],"install":[{"cmd":"pip install ipydatawidgets","lang":"bash","label":"PyPI"}],"dependencies":[{"reason":"Core dependency for interactive Jupyter widgets functionality. Requires version >=7.6.0,<9.","package":"ipywidgets","optional":false},{"reason":"Required for handling numerical array data, particularly with the NDArrayWidget.","package":"numpy","optional":false}],"imports":[{"note":"The primary widget for array data transfer.","symbol":"NDArrayWidget","correct":"from ipydatawidgets import NDArrayWidget"},{"note":"A trait type that accepts both NumPy arrays directly or a reference to an NDArrayWidget.","symbol":"DataUnion","correct":"from ipydatawidgets import DataUnion"}],"quickstart":{"code":"import numpy as np\nfrom ipydatawidgets import NDArrayWidget\n\n# Create some raw NumPy data\nraw_data = np.random.rand(10, 10, 3).astype(np.float32)\n\n# Wrap the raw data in an NDArrayWidget\ndata_widget = NDArrayWidget(raw_data)\n\n# The data_widget can now be passed to other widgets that accept NDArrayWidget instances\n# For demonstration, we'll just display it (though NDArrayWidget itself doesn't have a complex visual representation out of the box)\ndata_widget","lang":"python","description":"This example demonstrates how to create and use the core `NDArrayWidget` to encapsulate NumPy array data. This widget can then be linked to other ipywidgets-based components that are designed to consume `NDArrayWidget` instances or `DataUnion` types."},"warnings":[{"fix":"Run `jupyter labextension install @jupyter-widgets/jupyterlab-manager` in your environment after installing `ipydatawidgets`. For JupyterLab 3.x+, ensure `jupyterlab_widgets` is installed and up to date.","message":"When using JupyterLab 1 or 2, you may need to manually install the JupyterLab extension. Modern JupyterLab 3.x+ usually auto-configures `ipywidgets` support.","severity":"gotcha","affected_versions":"<4.0 (for older JupyterLab)"},{"fix":"Ensure your `ipywidgets` installation is within the compatible range: `pip install 'ipywidgets>=7.6.0,<9'`.","message":"ipydatawidgets requires `ipywidgets` version >=7.6.0 and <9. Using `ipywidgets` v9 or higher may lead to compatibility issues or 'Error displaying widget' messages, as underlying APIs might have changed.","severity":"breaking","affected_versions":"All versions with `ipywidgets` >=9"},{"fix":"Consult the `ipywidgets` migration guides for custom widget authors, specifically for migrating from 6.x to 7.x, and from 7.x to 8.x. Update module versions and webpack configurations accordingly.","message":"For developers creating custom widget libraries that integrate `ipydatawidgets`, be aware of breaking changes in `ipywidgets` itself (e.g., between v6, v7, and v8). These often involve updates to `_view_module_version`, `_model_module_version`, and `webpack` configurations.","severity":"gotcha","affected_versions":"Developers building custom widgets that depend on ipywidgets API"}],"env_vars":null,"last_verified":"2026-04-16T00:00:00.000Z","next_check":"2026-07-15T00:00:00.000Z","problems":[{"fix":"Ensure `ipywidgets` is correctly installed and compatible with your Jupyter environment. For JupyterLab, try `pip install jupyterlab_widgets` and potentially `jupyter labextension disable @jupyter-widgets/jupyterlab-manager && jupyter labextension enable @jupyter-widgets/jupyterlab-manager`. For classic Notebook, ensure `widgetsnbextension` is enabled. Check your `ipywidgets` version against `ipydatawidgets` requirements.","cause":"This common error typically indicates that the Jupyter frontend (Notebook or Lab) cannot load or render the widget's JavaScript component. This is often due to missing or incompatible `ipywidgets` extensions, or conflicting Python/JavaScript widget versions.","error":"Error displaying widget"},{"fix":"Verify that you are using a consistent Python environment (e.g., solely Anaconda's Python). Sometimes, reinstalling `ipywidgets`, `notebook`, or even your Anaconda environment can resolve deep-seated DLL conflicts. `conda update --all` or creating a fresh environment is often recommended.","cause":"This error, often seen on Windows within Anaconda environments, typically points to conflicts between different Python installations or environment issues affecting underlying libraries like `tornado` or `ssl` that `notebook` (and thus `ipywidgets`) depends on.","error":"ImportError: DLL load failed: The specified procedure could not be found."},{"fix":"Ensure `ipywidgets` and `jupyterlab_widgets` (or `widgetsnbextension` for classic Notebook) are compatible. For `ipydatawidgets`, stick to `ipywidgets <9`. If you are developing a custom widget, verify your `_model_name`, `_view_name`, `_model_module`, `_view_module`, and their respective `_module_version` traits are correctly defined and match the expected `ipywidgets` API.","cause":"This specific error often arises when there's an incompatibility between the versions of `ipywidgets` (especially v8) and `jupyterlab-widgets` (especially v3) or when a custom widget's frontend model isn't properly registered or is incompatible with the manager.","error":"Model class 'JupyterComm...' not found in registry (or similar 'Model class ... not found')"}]}