or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Syncing
xxxxxxxxxx
tags:
work-log
gsod
docs
GSOD 2021
Join Zoom Meeting
https://zoom.us/j/91573235246?pwd=TUQ2Mi9ablFzWU9xRzBZcnVrTzBaUT09
03/01/2021
Agenda (Jerome)
Updates
make html
See also https://github.com/matplotlib/matplotlib/issues/19578
List-style syntax:
https://docutils.sourceforge.io/docs/ref/rst/directives.html#list-table
can be fixed by reinstalling (
pip install -e .
)Planned Tasks
02/22/2021
Agenda (Jerome)
Updates
Planned Tasks
Figure
when discussing the class.02/7/2021
Agenda (Bruno)
LineStyle._linestyle_spec
(i.e. what the user passed in).__eq__
controls==
andin [...]
,__hash__
controls dict access andin {...}
__eq__
, we can doself.get_dashes() == LineStyle(other).get_dashes()
__eq__
and__hash__
for classX
then:X(a) == X(b)
=>hash(X(a)) == hash(X(b))
X(a) == b
==>hash(X(a)) == hash(b)
__eq__
(becauseother
lets us "infer" what the user is tryign to do), we have to actually make a hard choice with__hash__
:Always hash the (offset, onoffseq)
[NOPE, have to implement
__hash__
to match__eq__
] Hash the normalized name if it exists, otherwise the (offset, onoffseq)[NOPE] Hash whatever the user passed in
test = {'red': 1, 'blue': 2, (255, 0, 0): 3}
test[Color('red')] # always keyerror
docs
Off-topic
Artist reorg:
"Bruno language":
Current state:
Ideally:
Re: 2D layout
2D layout is hard…
…but at least we don't need to reflow. If I were designing mpl from scratch, here's how I would do it.
Matplotlib figures are made of a tree of "LayoutRect"s, where a LayoutRect is basically just a Bbox:
the offset (x, y) position of each LayoutRect is defined relative to the coordinate system of the parent LayoutRect.
The relationship between most nodes in this tree are highly constrained. A LayoutRect can have two types of children:
Each LayoutRect can have some optional constraints:
otherwise, (width, height) float to accomodate the requested size.
The layout engine, in general, would simply solve each FixedChildren tree (starting at Figure and traversing down recursively) for its location. This would happen in a totally separate pass to drawing.
Notice in particular this would mean that each Drawable that relies on nonlinear transforms would need to manually define its extents (e.g. each CRS), optionally as a function of having an arbitrary linear transform applied afterwards (to allow it to be e.g. rotated/sheared and still be tightly layed out).
Agenda (Jerome)
Updates
Axes contain Figure elements
discussion pointPlanned Tasks
02/1/2021
Agenda (Bruno)
Updates
LineStyle('-') == LineStyle((0, (,)))
should evaluate toTrue
.LineStyle('-') == LineStyle((0, (,)))
can change if rcParams changes.LineStyle('-').is_dashed()
return False ifrcParams['lines.solid_linestyle']
is actually dashed?mpl.rcParams['lines.solid_linestyle'] = LineStyle((0, (1, 2, 3, 4))) # LineStyle('-').is_dashed => True
LineStyle: solid = 'solid'; _solid_alias = '-'
??LineStyle(str, Enum)
Updates
12/23/2020
Agenda (Bruno)
Updates
Needs review, sphinx ext https://github.com/matplotlib/matplotlib/pull/19063
https://github.com/matplotlib/matplotlib/pull/18544
Needs discussion https://github.com/matplotlib/matplotlib/blob/e23afa27b7786183d273d200e5352ea41bd1af96/lib/matplotlib/_enums.py
LineStyle.dashed
LineStyle(LineStyle('dashed'))
LineStyle(NamedLineStyle('dashed'))
LineStyle((0, [1, 2, 3, 4]))
LineStyle([1, 2, 3, 4])
LineStyle([1, 2, 3, 4], offset=2.1)
LineStyle((2.1, [1, 2, 3, 4]))
Not:
Conclusion: above was well-meaning at best idea. Don't forget to move positivity check to creation time.
Resolution
with plt.rc_context(
We don't want any explicit dash-style. It's a subset of
LineStyle
andLineStyle([1, 2, 3, 4])
without an explicit offset should work. See also https://github.com/matplotlib/matplotlib/issues/1748312/23/2020
Agenda (Jerome)
Updates
The operation was canceled.
indexing is intended to occur at rendering time, and defaults to black if the cycle does not include color
and
"CN" colors are converted to RGBA as soon as the artist is created
Indexing occurs at rendering time and defaults to black if cycle does not include color.
and
"CN" colors convert to RGBA when creating Artists.
Planned tasks
Agenda (Bruno)
Updates
12/22/2020
Completed tasks:
MarkerStyle
is a…"type". And it's currently not "used" inscatter
andLine2D
. Should probably centralize this color code, regardless of what it is, to avoid future inconsistency. (This ties into "Collection" issue below).General questions:
if isinstance(ls, LineStyle): ls = ls else: ls = LineStyle(ls)
.onoffseq
. However, subclasses ofEnum
(specifically, classes with metaclassEnumMeta
) force each instance of the class to be a singleton (one for each class attribute). In general, this is a problem with "extensible" types, i.e. those with a fixed set of strings as options as well as a more general fallback. For example,MarkerStyle
('x', 'o', … OR an arbitraryPath
),LineStyle
(':', '-', … OR an onoffseq). Non-extensible types (i.e. those that truly are a collection of fixed strings) do not have this problem. Some solutions.Enum
(FillStyle, JoinStyle, CapStyle, etc.). For extendable classes just subclassstr
or similar. We can add Idempotency, but we probably aren't getting any benefit from singleton-ness anyway (no reason to compare two instances withis
, right?)isinstance(js, Enum)
. Means_enums.py
maybe not the best name.JoinStyle(str)
_strings.py
might still be a reasonable name.__new__
to remove the singleton property (soJoinStyle('miter') is JoinStyle('miter')
will now beFalse
).Enum
anymore, technically,isinstance(js, Enum)
beingFalse
wil probably be pretty surprising.MarkerShape
", this is not really a problem. Because each collection only wants one of them.12/14/2020
Agenda (Jerome)
Updates
Planned Tasks
12/14/2020
Agenda (Bruno)
Updates
Planned
12/07/2020
Agenda (Jerome)
Updates
Planned tasks
12/02/2020
Postponed from Wednesday 11/30/2020.
Agenda (Jerome)
Updates
subplot_mosaic
reference?install
andlegend guide
external resources
only able to findHTML link success
Planned tasks
Agenda (Bruno)
Updates
TODO
11/23/2020
Agenda (Jerome)
Updates
git push origin
last night then saw"Files changed
165
" again- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →individually
.. currentmodule:: getting_started
.. autofunction:: my_plotter
WARNING: autodoc: failed to import function 'my_plotter' from module 'getting_started'; the following exception was raised: No module named 'getting_started'
checking consistency... /Users/jerome/Documents/matplotlib/doc/devel/style_guide.rst: WARNING: document isn't included in any toctree
Planned tasks
11/16/2020
Agenda (Jerome)
Updates
:ref:`anatomy-of-a-figure`
.. currentmodule:: getting_started
.. autofunction:: my_plotter
WARNING: autodoc: failed to import function 'my_plotter' from module 'getting_started'; the following exception was raised: No module named 'getting_started'
Planned Tasks
Agenda (Bruno)
Updates
Planned Tasks
11/09/2020
Agenda (Bruno)
Updates
Planned Tasks
Agenda (Jerome)
Updates
make html
when building docs for getting_started.pyPlanned Tasks
11/02/2020
Agenda (Jerome)
Updates
Planned Tasks
Final Deliverables:
10/26/2020
Agenda (Jerome)
Updates
Planned Tasks
Agenda (Bruno)
Updates
Planned Tasks
10/20/2020
Agenda (Jerome)
Updates
Planned Tasks
Agenda (Bruno)
Updates
/home/bbeltr1/developer/matplotlib/lib/matplotlib/_types.py:docstring of matplotlib._types.CapStyle:1: WARNING: py:class reference target not found: matplotlib._types._AutoStringNameEnum
Planned tasks
10/13/2020
Agenda (Jerome)
Updates
Planned tasks
10/6/2020
Agenda (Jerome)
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →Agenda (Bruno)
Line2D
. Is this intended behavior? Should I be accepting dashes in both places? In addition, rc accepts any upper/lower-case but that's not allowed other places.rcParams['lines.dashed_pattern']
, etc)__init__
instead of lazily (as needed) after reading in the text.set_*
methods.get_linestyle
.draw
, which is the only place it's toucheddedent_interpd
string interpolation of the docs, and calling methods likeLineStyle.allowed_strings
to populate theinterpd
databasededent_interpd
, now that centralized classes hold the relevant strings, we can just import them and using mostly-standard formatting tools (basically just interpd but without the global database, this is guaranteed to always work because the presence of%(Class)
in a module always means that module has to import that class anyway), e.g.:dedent_interpd
andartist.kwdoc
unnecessary (not necessarily get rid of them, but make it just as easy to just refer to already-"linked" docs as described above)_types
classes are required by each public class (e.g. currently a "Patch" claims to just be an artist with a face and edge color, but like, it's more like an artist with a "fill" and a "border line", which means it can be described as "fill"_types
+Line2D
)9/29/2020
Agenda (Shared)
Agenda (Bruno)
Updates
Planned tasks
JoinStyle
/CapStyle
.LineStyle
,FillStyle
implemented.Agenda (Jerome)
Updates
Planned tasks
9/22/2020
Agenda (shared)
Agenda (Bruno)
joinstyle
)help()
and IPython?name
calls.complexity * rarity
, so that a user can learn advanced Matplotlib features just by scrolling down.Path
in the linked PR?and some that are already classes:
Planned tasks
Agenda (Jerome)
Updates
Planned tasks
9/15/2020
Goals
Agenda
reporting?
tentative plans for the first month
Bruno
Jerome
9/8/2020
9/3/2020
linking between dev/release/old docs
docs that are tagged to versions vs not
tagged to versions
not tagged to versions
search engines redirecting to old versions
already been done
have prs
things to do
computer/environment specific install issues
for next week