Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Consider MatRepr for__repr__ instead of Pandas #494

Open
@alugowski

Description

@alugowski

https://pypi.org/project/matrepr/

Benefits:

  • output looks like a matrix, not a dataframe
  • faster, especially on first run where the pandas import is slow
  • small code

See it in action with python-graphblas:
https://nbviewer.org/github/alugowski/matrepr/blob/main/doc/demo-python-graphblas.ipynb

To try yourself, use matrepr's jupyter integration (causes Jupyter to use matrepr's formatter instead of the native one):

importmatrepr.jupyter

For the Python REPL, a__repr__ monkey patch does the same:

importmatrepr.patch.graphblas

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp