Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add documentation for using ComponentGraphs #2673

Merged
merged 28 commits into from Sep 5, 2021
Merged

Add documentation for using ComponentGraphs #2673

merged 28 commits into from Sep 5, 2021

Conversation

angela97lin
Copy link
Contributor

@angela97lin angela97lin commented Aug 23, 2021

@angela97lin angela97lin self-assigned this Aug 23, 2021
@codecov
Copy link

codecov bot commented Aug 23, 2021

Codecov Report

Merging #2673 (3349959) into main (e01d736) will increase coverage by 0.8%.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##            main   #2673     +/-   ##
=======================================
+ Coverage   99.2%   99.9%   +0.8%     
=======================================
  Files        301     301             
  Lines      27819   27819             
=======================================
+ Hits       27573   27770    +197     
+ Misses       246      49    -197     
Impacted Files Coverage Δ
evalml/tests/automl_tests/test_automl.py 99.7% <0.0%> (+0.1%) ⬆️
evalml/automl/utils.py 100.0% <0.0%> (+1.7%) ⬆️
...lml/tests/automl_tests/test_iterative_algorithm.py 100.0% <0.0%> (+4.5%) ⬆️
evalml/tests/automl_tests/test_automl_utils.py 100.0% <0.0%> (+9.4%) ⬆️
.../automl_tests/test_automl_search_classification.py 100.0% <0.0%> (+10.6%) ⬆️
...ests/automl_tests/test_automl_search_regression.py 100.0% <0.0%> (+15.5%) ⬆️
evalml/automl/pipeline_search_plots.py 100.0% <0.0%> (+53.6%) ⬆️
...l/tests/automl_tests/test_pipeline_search_plots.py 100.0% <0.0%> (+74.5%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e01d736...3349959. Read the comment docs.

Copy link
Contributor

@eccabay eccabay left a comment

Choose a reason for hiding this comment

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

This looks great! I left a couple requests for small new sections.

The biggest thing missing for me is discussion of the flow of a graph, as was mentioned in the original issue. I would love to see a section talking about compute order, and how to know what components to link together and how. There's a little bit of that implicitly shown in the larger example, but it would be great to have a whole section dedicated to discussing it.

"source": [
"## Defining a Component Graph\n",
"\n",
"Component graphs can be defined by specifying the dictionary of components and edges that describe the graph. In this dictionary, each key is the name that should be used to reference a component by, and each corresponding value is a list where the first element is the component or component name, and the remaining elements are the input edges that should be connected to that component.\n",
Copy link
Contributor

Choose a reason for hiding this comment

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

A couple suggestions, feel free to take them or leave them!

  • We could reference Dask computation graphs, since the component graph design was originally modeled after them
  • "In this dictionary, each key is the name that should be used to reference a component by, and each corresponding value is a list where the first element is the component or component name, and the remaining elements are the input edges that should be connected to that component." --> "In this dictionary, each key is a reference name for a component. Each corresponding value is a list, where the first element is the component itself, and the remaining elements are the input edges that should be connected to that component. The component as listed in the value can either be the component object itself or its string name."

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 love this, thank you for the context!

(Long sentences have always been my weakness, thank you for helping me break it down 😁)

docs/source/user_guide/component_graphs.ipynb Outdated Show resolved Hide resolved
"cell_type": "markdown",
"metadata": {},
"source": [
"## Visualizing Component Graphs\n",
Copy link
Contributor

Choose a reason for hiding this comment

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

It may be worth it to highlight ComponentGraph.describe() here as well!

"source": [
"## Components in the Component Graph\n",
"\n",
"You can use `.get_component(name)` and provide the unique component name to access any component in the component graph. Below, we can grab our Imputer component and confirm that `numeric_impute_strategy` has indeed been set to \"most_frequent\"."
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you add a section about get_inputs here as well?

"source": [
"# Component Graphs\n",
"\n",
"EvalML component graphs represent and describe the flow of data in a collection of related components. A component graph is comprised of nodes representing components, and edges between pairs of nodes representing where the inputs and outputs of each component should go. It is the backbone of the features offered by the EvalML [pipeline](pipelines.ipynb), but is also a powerful data structure on its own. EvalML currently supports component graphs as linear and directed acyclic graphs (DAG)."
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe add a link to a description of what a DAG is here, for anyone unfamiliar with graph theory

Copy link
Contributor

@bchen1116 bchen1116 left a comment

Choose a reason for hiding this comment

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

Agreed with Becca's comments, but looks good!

docs/source/user_guide/component_graphs.ipynb Outdated Show resolved Hide resolved
Copy link
Collaborator

@chukarsten chukarsten left a comment

Choose a reason for hiding this comment

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

Looks solid to me! Thank you!

@chukarsten chukarsten merged commit 214be16 into main Sep 5, 2021
@chukarsten chukarsten deleted the 2367_cg_docs branch September 5, 2021 00:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add documentation for using ComponentGraphs
4 participants