Skip to content
This repository has been archived by the owner on Aug 21, 2023. It is now read-only.

Removing %matplotlib inline from different tutorials #1206

Merged
merged 12 commits into from
Jul 9, 2021

Conversation

divshacker
Copy link
Contributor

@divshacker divshacker commented Jun 28, 2021

Summary

fixes Qiskit/qiskit#1265
#1201

Details and comments

All details of this PR can be found in above linked issue

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@divshacker
Copy link
Contributor Author

divshacker commented Jun 28, 2021

Done! all the %matplotlib inline removed. @SooluThomas Please check and let us know if any further changes needed.

@singhmeet11
Copy link
Contributor

There were a few tutorials which were actually not using .draw('mpl') but had %matplotlib inline, @divshacker and I actually removed these ones too after having a discussion.
Reason - As soon as someone would add matplot lib images, they would start to double up creating a sort of mess. This won't happen now.

@divshacker
Copy link
Contributor Author

There were a few tutorials which were actually not using .draw('mpl') but had %matplotlib inline, @divshacker and I actually removed these ones too after having a discussion.
Reason - As soon as someone would add matplot lib images, they would start to double up creating a sort of mess. This won't happen now.

Exactly! Also if one runs the draw() without mpl option or %matplotlib inline the figure produced by default is mpl only. (If we install the correct and ideal qiskit environment eg. IBM quantum lab which have all things preinstalled).

Copy link
Member

@SooluThomas SooluThomas left a comment

Choose a reason for hiding this comment

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

LGTM

@SooluThomas SooluThomas merged commit 5cf9310 into Qiskit:master Jul 9, 2021
@divshacker divshacker deleted the matplotlib-fix-2 branch July 9, 2021 13:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

.draw(output = 'mpl') always produces two plots in Jupyter
3 participants