MNT: Should we re-organize shared agg files in /src ?
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 25/100
- issue の種類
- リファクタリング
- 明瞭さ
- 説明が足りない
- 活発さ
- 活発
調査の方向性
Read the listed shared headers in src/ and src/py_converters.cpp, then compare their dependency tree with the nanobind experiment branch linked in the issue. The issue asks for opinions on how to group and transition these files, but does not settle on a design; done means agreeing on a structure and migration approach for _backend_agg, _image, and _path.
索引モデルが issue の本文から書いたものです。
説明
We currently have 4 files in /src which are used by the _backend_agg, _image, and _path modules:
Additionally, we have py_converters.cpp which is only used by _image. If _path or _backend_end tries to use convert_trans_affine(), they will get a missing symbol at compile time.
The dependency tree looks like this:
During my nanobind work, I struggled to understand the grouping of these files and had several questions:
- Why is "_backend_agg_basic_types.h" named with the "backend" prefix when it is used by
_path? - Why do "path_converters" and "py_converters" end with a "converters" suffix when they implement two very different ideas?
- What is the difference between a "py_adapter" and the classes found in "_backend_agg_basic_types"?
- Why do we split
_backend_agg,_image, and_pathinto three modules when they all use agg? There's approximately 15% duplicated agg code and 10% duplicated pybind11 code present in the three modules. Most of the duplication is between_pathand_backend_agg. I understand why_imagemakes sense on its own.
I believe that the answer to all of these is "it's how the files have evolved over time and there hasn't been a need to change anything."
With the nanobind transition, I need to have nanobind variants of these files. I have the following options:
- Introduce nanobind variants of the files with different names. This allows me to transition
_backend_agg,_image, and_pathseparately. - Keep the files the same name and have giant
#ifdef USE_NANOBIND_IMPL/#ifdef USE_PYBIND11_IMPLblocks. - Keep the files the same name and move everything over in one PR.
I used the first option in my nanobind-experiment branch. However, I'm not sure if the original grouping of these files still makes sense.
Are there any strong opinions? Should we re-organize these in a different way?
- 主要言語
- Python
- スター
- 23.5k
- フォーク
- 8.6k
- 平均マージ
- 1日 19時間
- マージ済み PR(30日)
- 64
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
matplotlib/matplotlib のほかの issue
-
[Bug]: Saving a NonUniformImage with bbox_inches="tight" raises TypeError when extent is omittedオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
matplotlib/matplotlib#32707 ·
メンテナーはふだん 1 日以内に返信
-
[Bug]: withTickedStroke raises ValueError when the line contains NaN対応中かも @RjyavardhanSingh が 3 日前に担当しました。 オープンfirst-contribution topic: path handling
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
matplotlib/matplotlib#32689 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
[Bug]: Constrained layout raises ZeroDivisionError when the first height/width ratio is zero対応中かも @yqtian-se が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
matplotlib/matplotlib#32684 · コメント 3 件 ·
メンテナーはふだん 1 日以内に返信
-
[Bug]: twin axes ignore the navigation opt-outs対応中かも @NaumanRafay が 36 日前に担当しました。 オープンtopic: toolbar
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
matplotlib/matplotlib#32528 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
[Bug]: macOS font discovery raises KeyError('_items') for an incomplete system_profiler font recordオープンfirst-contribution OS: Apple status: needs clarification topic: text/fonts
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
matplotlib/matplotlib#32328 · コメント 4 件 ·
メンテナーはふだん 1 日以内に返信
matplotlib/matplotlib の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 78/100
nael5x/creative-ai#130 ·
-
Make the "%" unit spacing the same in the web and in A10対応中かも @kragent66-glitch が今日担当しました。 オープンbug good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
maiychrus25/OpenTea-DX-OS#226 · コメント 1 件 ·
-
ci severity: low
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
TMHSDigital/Spackle#205 ·
メンテナーはふだん 1 日以内に返信
-
pkg:lgm type:chore upstream-gaussx
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
jejjohnson/pyrox#610 ·
メンテナーはふだん 1 日以内に返信