Skip to content

Commit

Permalink
Move arrayviz to the top level of treescope.
Browse files Browse the repository at this point in the history
This reduces the nesting of arrayviz and removes the need to refer
to arrayviz.arrayviz directly.

PiperOrigin-RevId: 653404499
  • Loading branch information
danieldjohnson authored and Penzai Developers committed Jul 17, 2024
1 parent 9368bf9 commit 64380f0
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 22 deletions.
4 changes: 2 additions & 2 deletions penzai/pz/ts.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@

# pylint: disable=g-multiple-import,g-importing-member,unused-import

from penzai.treescope.arrayviz.array_autovisualizer import (
from penzai.treescope.array_autovisualizer import (
ArrayAutovisualizer,
)
from penzai.treescope.arrayviz.arrayviz import (
from penzai.treescope.arrayviz import (
default_diverging_colormap,
default_sequential_colormap,
integer_digitbox,
Expand Down
1 change: 1 addition & 0 deletions penzai/treescope/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
commonly-used treescope functions and classes.
"""

from . import array_autovisualizer
from . import arrayviz
from . import autovisualize
from . import canonical_aliases
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
import numpy as np
from penzai.core import named_axes
from penzai.core._treescope_handlers import named_axes_handlers
from penzai.treescope import arrayviz
from penzai.treescope import autovisualize
from penzai.treescope import ndarray_summarization
from penzai.treescope.arrayviz import arrayviz
from penzai.treescope.foldable_representation import basic_parts
from penzai.treescope.foldable_representation import common_structures
from penzai.treescope.foldable_representation import common_styles
Expand Down
File renamed without changes.
18 changes: 0 additions & 18 deletions penzai/treescope/arrayviz/__init__.py

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion penzai/treescope/treescope_ipython.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@

import jax.numpy as jnp

from penzai.treescope import array_autovisualizer
from penzai.treescope import autovisualize
from penzai.treescope import context
from penzai.treescope import default_renderer
from penzai.treescope import figures
from penzai.treescope import object_inspection
from penzai.treescope.arrayviz import array_autovisualizer
from penzai.treescope.foldable_representation import basic_parts
from penzai.treescope.foldable_representation import foldable_impl

Expand Down

0 comments on commit 64380f0

Please sign in to comment.