Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Added possibility to set description of cells that will be injected to the tqdm.
To add description to a specific cell the user must add a string with this formatting in the desired cell:
# papermill_description=description_of_cell
When the execution will reach that cell, the description of the tqdm will be changed from
Executing x:
toExecuting description_of_cell
.If no cell contains the tag
papermill_description=
, the execution will be as before the implementation of this functionality.If a cell containing the description tag is followed by cells that don't have the tag, the tqdm description is set to the last valid description.
I decided to implement this functionality because I think it is pretty useful with long notebooks that have very slow cells (i.e. data preparation and model training). An alternative can be to use logging, but it is way more verbose.
With this implementation you can simply add the 'Training' description to a cell and you know you are in the training process, or you can add 'Data_Preparation' and you know you are doing data preparation, moreover you see only the description of the current cell in the tqdm.
If a user doesn't like this functionality, he can simply ignore it.
I think it would be a good idea to add information about this feature in the documentation, but I would like to know first if this this is correctly implemented and perceived as a good addition from the authors/contributors.