Skip to content

Conversation

zaxtax
Copy link
Contributor

@zaxtax zaxtax commented Mar 30, 2025

This add the ability to pass in graph level attributes to the model_to_graphviz function. This makes it easier to tweak the layout of the graph.

Checklist

Type of change

  • New feature / enhancement
  • Bug fix
  • Documentation
  • Maintenance
  • Other (please specify):

📚 Documentation preview 📚: https://pymc--7741.org.readthedocs.build/en/7741/

@zaxtax zaxtax requested a review from jessegrabowski March 30, 2025 13:28
@zaxtax zaxtax force-pushed the add_attrs_to_graphviz branch from 80d49fb to 78fdd17 Compare March 30, 2025 13:30
figsize=None,
dpi=300,
node_formatters: NodeTypeFormatterMapping | None = None,
graph_attrs: GraphAttrMapping | None = None,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure I like the custom type, it makes it seem more complex than it really is. It's not much shorter than dict[str, Any]

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have no strong feelings about this other than it was to be more consistent with the rest of the file

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

up to you; not a blocker

Copy link

codecov bot commented Mar 30, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.82%. Comparing base (fb4b201) to head (dcf2b76).
Report is 41 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #7741   +/-   ##
=======================================
  Coverage   92.82%   92.82%           
=======================================
  Files         107      107           
  Lines       18324    18324           
=======================================
  Hits        17010    17010           
  Misses       1314     1314           
Files with missing lines Coverage Δ
pymc/model_graph.py 87.25% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

zaxtax and others added 2 commits March 30, 2025 16:22
@zaxtax zaxtax requested a review from jessegrabowski March 30, 2025 16:23
@ricardoV94 ricardoV94 changed the title Add a way to pass in graph level attributes to graphviz Allow passing graph level attributes to graphviz Mar 31, 2025
@ricardoV94 ricardoV94 merged commit 6ef135b into pymc-devs:main Mar 31, 2025
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants