Skip to main content

Tools for interactive visualization and exploration of _data maps_

Project description

TNT Logo

This Not That (TNT)

This Not That is a suite of tools for working with, exploring, and interacting with “data maps”. A data map is a two (or three) dimensional representation of higher dimensional vector space data, usually produced by UMAP, t_SNE, or another manifold learning technique. The goal of This Not That is to make it quick and easy to visualize, enrich and interact with data maps. This not that also aims to make it easy to build and deploy simple web-apps on top of data maps to let other users gain access to rich interactive data maps as a means to explore data sets.

This Not That for Labelling

This Not That makes it easy to quickly build an interactive data labeller directly in your notebook, allowing you to quickly tag data for further analysis, extract interesting samples, or do an initial round of bulk labelling.

This Not That for Exploration

This Not That makes it easy to get an interactive plot of a data map, but also allows you to quickly connect other tools to it, including powerful search utilities, a rich data instance viewer, data tables tied to in-plot selections, and tools for quickly adjusting plot attributes from lists of extra variables.

This Not That also provides a variety of automated solutions for adding textual annotation layers to data maps, providing easier navigation and exploration.

This Not That for Data Map Apps

Because This Not That is built on top of the Panel library it is trivial to deploy TNT based solutions as interactive web applications.

Documentation

Get the latest on Read The Docs.

Installing

JUPYTER HUB WARNING: attempting to use a TNT notebook in conjunction with a jupyter hub instance can result in broken linkages between the selections for your various panel panes. If you are running on jupyter hub server and can select points in one of your plots but it isn’t updating any other plots then this is the likely culprit. Fixing this requires that the same versions of the Panel library and bokeh are installed in the main kernel that starts the jupyter hub server and the local kernel. If you are running on a groups jupyterhub server this may require you contacting the administrator and asking them to install your favorite versions of bokeh and panel before restarting their server. I’d recommend you then record the version information for your team so that they can easily match the versions in their local kernels.

This Not That is built on top of Panel and Bokeh, so you will need these installed. In all you will need:

  • panel

  • bokeh

  • numpy >= 1.22

  • pandas

  • scikit-learn

  • matplotlib

  • umap-learn

  • hdbscan

  • glasbey

  • cmocean

  • vectorizers

We also highly recommend installing:

  • networkx

  • apricot-select

Currently you can pip install from PyPI:

pip install thisnotthat

Or directly from this repository:

pip install git+https://github.com/TutteInstitute/thisnotthat

Contributing

Contributions are more than welcome! There are lots of opportunities for potential projects, so please get in touch if you would like to help out. Everything from code to notebooks to examples and documentation are all equally valuable so please don’t feel you can’t contribute. We are also keen to hear user stories and suggestions for new Pane’s to add to to our catalog. We also welcome contributions to get other plot libraries integrated and working with TNT, including plotly, VTK/PyVista, and others, so if you have expertise with these please consider contributing.

To contribute please fork the project make your changes and submit a pull request. We will do our best to work through any issues with you and get your code merged into the main branch.

Development

To create a development environment clone the repo and install the package in editable mode

pip install -e .[tests]

To run unit tests

pytest thisnotthat/tests

UI tests are done using Playwright and build on Panel’s UI tests. They are not run by default and require the –ui flag. Note that this only runs the UI tests. You can install a browser for Playwright and use it to run tests:

playwright install chromium
pytest thisnotthat/tests/ --ui --browser chromium -n 1

or use an existing browser on your machine such as Chrome

pytest thisnotthat/tests/ --ui --browser-channel chrome -n 1

License

The This Not That package is 3-clause BSD licensed.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

thisnotthat-0.4.2.tar.gz (56.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

thisnotthat-0.4.2-py3-none-any.whl (63.5 kB view details)

Uploaded Python 3

File details

Details for the file thisnotthat-0.4.2.tar.gz.

File metadata

  • Download URL: thisnotthat-0.4.2.tar.gz
  • Upload date:
  • Size: 56.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.15

File hashes

Hashes for thisnotthat-0.4.2.tar.gz
Algorithm Hash digest
SHA256 cb7332d617c32f595b4011bde74867df6c9d1de329f19532d2e377a689ce2bba
MD5 1e0e0f2d23e465b172c9ac51479348d0
BLAKE2b-256 afdc3c5fdb229a3615918eb8ced313a73f4bc2b34d9bda650993db193d32ea3e

See more details on using hashes here.

File details

Details for the file thisnotthat-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: thisnotthat-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 63.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.15

File hashes

Hashes for thisnotthat-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4749ff99b2b5067fdff38183aa9e3b1fc97faf495d7c4d4ae8e219da22e87bf8
MD5 b7df947ebacba713ced4a275fed53ed4
BLAKE2b-256 62b3a6c3186b9ffc183be5aa4db481eda72d0736c5ebac6bdac77bc678ff6503

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page