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

Doc pipelines #6175

Merged
merged 6 commits into from
Aug 3, 2020
Merged

Doc pipelines #6175

merged 6 commits into from
Aug 3, 2020

Conversation

sgugger
Copy link
Collaborator

@sgugger sgugger commented Jul 31, 2020

Continue the improvement of the main classes documentation with pipelines.

Preview of the new pipeline page.
Preview of the new pipeline utils page.

Generative models
~~~~~~~~~~~~~~~~~

Coming soon
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Will be my next PR doc, but I needed the anchor to make a link in several docstrings of Pipeline subclasses.


TokenClassificationPipeline
ConversationalPipeline
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Just a reorderin by alphabetical order and put the main Pipeline class at the end since it's more abstract.

@@ -408,7 +497,7 @@ def __init__(
):

if framework is None:
framework = get_framework()
framework = get_framework(model)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is what the pipeline function does, seemed good to do it too, in case a user is directly using the subclasses.

@codecov
Copy link

codecov bot commented Jul 31, 2020

Codecov Report

Merging #6175 into master will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #6175   +/-   ##
=======================================
  Coverage   79.51%   79.52%           
=======================================
  Files         146      146           
  Lines       26607    26618   +11     
=======================================
+ Hits        21156    21167   +11     
  Misses       5451     5451           
Impacted Files Coverage Δ
src/transformers/pipelines.py 79.79% <100.00%> (+0.42%) ⬆️
src/transformers/tokenization_xlm_roberta.py 84.52% <0.00%> (-10.72%) ⬇️
src/transformers/tokenization_utils_base.py 92.71% <0.00%> (-1.13%) ⬇️
src/transformers/file_utils.py 80.05% <0.00%> (-0.26%) ⬇️
src/transformers/tokenization_t5.py 95.77% <0.00%> (+23.94%) ⬆️

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 d951c14...1ec7448. Read the comment docs.

Copy link
Member

@LysandreJik LysandreJik left a comment

Choose a reason for hiding this comment

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

Very nice!

src/transformers/pipelines.py Outdated Show resolved Hide resolved
src/transformers/pipelines.py Outdated Show resolved Hide resolved
Lysandre comments

Co-authored-by: Lysandre Debut <lysandre@huggingface.co>
@sgugger sgugger merged commit e4920c9 into master Aug 3, 2020
@sgugger sgugger deleted the doc_pipelines branch August 3, 2020 15:44
Mehrad0711 pushed a commit to Mehrad0711/transformers that referenced this pull request Aug 3, 2020
* Init work on pipelines doc

* Work in progress

* Work in progress

* Doc pipelines

* Rm unwanted default

* Apply suggestions from code review

Lysandre comments

Co-authored-by: Lysandre Debut <lysandre@huggingface.co>

Co-authored-by: Lysandre Debut <lysandre@huggingface.co>
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.

None yet

2 participants