You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is because we changed the arguments passed to the function to make it more general (see here).
Proposed solution
The fix needs to account that differential_displacement now returns a matplotlib figure object, that can be saved later directly in plot_vitek.
When plot_vitek is called in dislocation.show_NEB_configurations(), there is a little change to make to be able to add new vitek plots on top of each other.
In the meantime, one can still use versions of atomman that are <=1.2.3.
The text was updated successfully, but these errors were encountered:
Basically it wiped out the changes of my pull request where I aded possibility of passing matplotlib axes to the function via plot_axes argument.
Was it actually done by purpose? If not it would be grate if you can reverse it. Alternatively I can reimplement it and to another pull request.
This is more preferable that a returning a figure since one can imagine having a figure with multiple axes. When you force to create a new figure on every function call you limit the usage of the function to figures with single axes.
Having control over you figure and axes outside the plotting function also would allow you to add impurities and any extra data and makes the function much more versatile. This is also a standard behaviour for plotting functions in the modules built on top of the matplotlib. See seabron as an example: https://github.com/mwaskom/seaborn
Hi,
Error
In
matscipy.dislocation.plot_vitek()
, the call to the atomman package functiondifferential_displacement
provokes the following error :TypeError: differential_displacement() got an unexpected keyword argument 'show'
with atomman version
>1.2.4
.Piece of code involved
Below, the call to atomman in matscipy :
Reason
It is because we changed the arguments passed to the function to make it more general (see here).
Proposed solution
The fix needs to account that
differential_displacement
now returns a matplotlib figure object, that can be saved later directly inplot_vitek
.When
plot_vitek
is called indislocation.show_NEB_configurations()
, there is a little change to make to be able to add new vitek plots on top of each other.In the meantime, one can still use versions of atomman that are
<=1.2.3
.The text was updated successfully, but these errors were encountered: