diplotocus 0.4.2__tar.gz → 0.5.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. {diplotocus-0.4.2 → diplotocus-0.5.1}/PKG-INFO +1 -1
  2. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/index.rst +1 -1
  3. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/GUI.ipynb +5 -0
  4. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/animations.ipynb +152 -0
  5. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/plot_objects.ipynb +9 -0
  6. diplotocus-0.5.1/src/diplotocus/_version.py +1 -0
  7. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/animations.py +754 -96
  8. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/core.py +41 -17
  9. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus.egg-info/PKG-INFO +1 -1
  10. diplotocus-0.4.2/src/diplotocus/_version.py +0 -1
  11. {diplotocus-0.4.2 → diplotocus-0.5.1}/.gitattributes +0 -0
  12. {diplotocus-0.4.2 → diplotocus-0.5.1}/.gitignore +0 -0
  13. {diplotocus-0.4.2 → diplotocus-0.5.1}/.readthedocs.yaml +0 -0
  14. {diplotocus-0.4.2 → diplotocus-0.5.1}/LICENSE +0 -0
  15. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/Makefile +0 -0
  16. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/_static/force-light.css +0 -0
  17. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/_static/force-light.js +0 -0
  18. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/make.bat +0 -0
  19. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/requirements.txt +0 -0
  20. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/Web_GUI.png +0 -0
  21. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/button.svg +0 -0
  22. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/demo.mp4 +0 -0
  23. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/favicon.ico +0 -0
  24. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/force-light.css +0 -0
  25. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/force-light.js +0 -0
  26. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/logo.mp4 +0 -0
  27. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/_static/logo.svg +0 -0
  28. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/api/core.rst +0 -0
  29. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/api/index.rst +0 -0
  30. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/conf.py +0 -0
  31. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/easings.ipynb +0 -0
  32. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/index.ipynb +0 -0
  33. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/installation.ipynb +0 -0
  34. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/quick-start.ipynb +0 -0
  35. {diplotocus-0.4.2 → diplotocus-0.5.1}/docs/source/notebooks/timeline.ipynb +0 -0
  36. {diplotocus-0.4.2 → diplotocus-0.5.1}/logo.png +0 -0
  37. {diplotocus-0.4.2 → diplotocus-0.5.1}/pyproject.toml +0 -0
  38. {diplotocus-0.4.2 → diplotocus-0.5.1}/readme.md +0 -0
  39. {diplotocus-0.4.2 → diplotocus-0.5.1}/setup.cfg +0 -0
  40. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/GUI.html +0 -0
  41. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/__init__.py +0 -0
  42. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/app.js +0 -0
  43. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/server.py +0 -0
  44. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/bg.png +0 -0
  45. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Draw.png +0 -0
  46. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Morph.png +0 -0
  47. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Rotate.png +0 -0
  48. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Scale.png +0 -0
  49. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Sequence.png +0 -0
  50. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Translate.png +0 -0
  51. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_Tween.png +0 -0
  52. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/btn/btn_bg_default.png +0 -0
  53. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/favicon.ico +0 -0
  54. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/src/logo_bg.png +0 -0
  55. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/GUI/style.css +0 -0
  56. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/__init__.py +0 -0
  57. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus/easings.py +0 -0
  58. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus.egg-info/SOURCES.txt +0 -0
  59. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus.egg-info/dependency_links.txt +0 -0
  60. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus.egg-info/requires.txt +0 -0
  61. {diplotocus-0.4.2 → diplotocus-0.5.1}/src/diplotocus.egg-info/top_level.txt +0 -0
  62. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test.py +0 -0
  63. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test10.py +0 -0
  64. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test2.py +0 -0
  65. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test3.py +0 -0
  66. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test4.py +0 -0
  67. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test5.py +0 -0
  68. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test6.py +0 -0
  69. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test7.py +0 -0
  70. {diplotocus-0.4.2 → diplotocus-0.5.1}/tests/test8.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: diplotocus
3
- Version: 0.4.2
3
+ Version: 0.5.1
4
4
  Summary: A python package to generate animations of matplotlib objects.
5
5
  Author-email: Tristan Boin <tristan.boin@obspm.fr>
6
6
  License-Expression: MIT
@@ -45,7 +45,7 @@ Here's a quick example of the syntax of diplotocus:
45
45
  tl.animate(p)
46
46
 
47
47
  #We render our video
48
- tl.save_video(path='../_static/demo.mp4')
48
+ tl.save_video(path='demo.mp4')
49
49
 
50
50
  .. raw:: html
51
51
 
@@ -11,6 +11,11 @@
11
11
  "\n",
12
12
  "![](../_static/Web_GUI.png)\n",
13
13
  "\n",
14
+ "```{warning}\n",
15
+ "\n",
16
+ "The GUI might not be as stable as the python interface. Feel free to report any issues you encounters.\n",
17
+ "```\n",
18
+ "\n",
14
19
  "When running diplotocus through this mode, you will make edit your animation through a local web page in your browser. This page communicates with a python server, which links the GUI and diplotocus objects in the background. Hence, everything you can do through python, you can do through the GUI, and vice versa.\n",
15
20
  "\n",
16
21
  "```{note}\n",
@@ -817,6 +817,82 @@
817
817
  "tl.save_video('../_static/animations/axis_limits.mp4')"
818
818
  ]
819
819
  },
820
+ {
821
+ "cell_type": "markdown",
822
+ "id": "463d3df9",
823
+ "metadata": {},
824
+ "source": [
825
+ "### Axis pos and size\n",
826
+ "\n",
827
+ "```{eval-rst}\n",
828
+ ".. automethod:: diplotocus.animations.axis_pos_and_size\n",
829
+ " :noindex:\n",
830
+ "```"
831
+ ]
832
+ },
833
+ {
834
+ "cell_type": "code",
835
+ "execution_count": 4,
836
+ "id": "c01a5513",
837
+ "metadata": {},
838
+ "outputs": [
839
+ {
840
+ "data": {
841
+ "application/vnd.jupyter.widget-view+json": {
842
+ "model_id": "0c53fc7065614884aba3cfb420806912",
843
+ "version_major": 2,
844
+ "version_minor": 0
845
+ },
846
+ "text/plain": [
847
+ " 0%| | 0/60 [00:00<?, ?it/s]"
848
+ ]
849
+ },
850
+ "metadata": {},
851
+ "output_type": "display_data"
852
+ },
853
+ {
854
+ "data": {
855
+ "text/markdown": [
856
+ "Saved video ../_static/animations/axis_pos_and_size.mp4"
857
+ ],
858
+ "text/plain": [
859
+ "<IPython.core.display.Markdown object>"
860
+ ]
861
+ },
862
+ "metadata": {},
863
+ "output_type": "display_data"
864
+ },
865
+ {
866
+ "data": {
867
+ "text/html": [
868
+ "\n",
869
+ " <video width=\"640\" height=\"360\" autoplay loop muted playsinline>\n",
870
+ " <source src=\"../_static/animations/axis_pos_and_size.mp4?randId=4292\" type=\"video/mp4\">\n",
871
+ " </video>\n",
872
+ " "
873
+ ],
874
+ "text/plain": [
875
+ "<IPython.core.display.HTML object>"
876
+ ]
877
+ },
878
+ "metadata": {},
879
+ "output_type": "display_data"
880
+ }
881
+ ],
882
+ "source": [
883
+ "import diplotocus as dpl\n",
884
+ "import matplotlib.pyplot as plt\n",
885
+ "\n",
886
+ "fig,ax = plt.subplots(1,2)\n",
887
+ "\n",
888
+ "tl = dpl.Timeline(fig=fig)\n",
889
+ "\n",
890
+ "a = dpl.axis_pos_and_size(start_width=0.0,end_width=0.4,duration=60,axis=ax[1])\n",
891
+ "\n",
892
+ "tl.animate(a)\n",
893
+ "tl.save_video('../_static/animations/axis_pos_and_size.mp4')"
894
+ ]
895
+ },
820
896
  {
821
897
  "cell_type": "markdown",
822
898
  "id": "bc66aa88",
@@ -894,6 +970,82 @@
894
970
  "tl.save_video('../_static/animations/axis_move.mp4')"
895
971
  ]
896
972
  },
973
+ {
974
+ "cell_type": "markdown",
975
+ "id": "fc9ac910",
976
+ "metadata": {},
977
+ "source": [
978
+ "### Axis track\n",
979
+ "\n",
980
+ "```{eval-rst}\n",
981
+ ".. automethod:: diplotocus.animations.axis_track\n",
982
+ " :noindex:\n",
983
+ "```"
984
+ ]
985
+ },
986
+ {
987
+ "cell_type": "code",
988
+ "execution_count": 2,
989
+ "id": "15283849",
990
+ "metadata": {},
991
+ "outputs": [
992
+ {
993
+ "data": {
994
+ "application/vnd.jupyter.widget-view+json": {
995
+ "model_id": "698754ccec1b4218be341de8f233a3fc",
996
+ "version_major": 2,
997
+ "version_minor": 0
998
+ },
999
+ "text/plain": [
1000
+ " 0%| | 0/60 [00:00<?, ?it/s]"
1001
+ ]
1002
+ },
1003
+ "metadata": {},
1004
+ "output_type": "display_data"
1005
+ },
1006
+ {
1007
+ "data": {
1008
+ "text/markdown": [
1009
+ "Saved video ../_static/animations/axis_track.mp4"
1010
+ ],
1011
+ "text/plain": [
1012
+ "<IPython.core.display.Markdown object>"
1013
+ ]
1014
+ },
1015
+ "metadata": {},
1016
+ "output_type": "display_data"
1017
+ },
1018
+ {
1019
+ "data": {
1020
+ "text/html": [
1021
+ "\n",
1022
+ " <video width=\"640\" height=\"360\" autoplay loop muted playsinline>\n",
1023
+ " <source src=\"../_static/animations/axis_track.mp4?randId=6295\" type=\"video/mp4\">\n",
1024
+ " </video>\n",
1025
+ " "
1026
+ ],
1027
+ "text/plain": [
1028
+ "<IPython.core.display.HTML object>"
1029
+ ]
1030
+ },
1031
+ "metadata": {},
1032
+ "output_type": "display_data"
1033
+ }
1034
+ ],
1035
+ "source": [
1036
+ "import diplotocus as dpl\n",
1037
+ "\n",
1038
+ "tl = dpl.Timeline(xlim=(-2,2),ylim=(-2,2))\n",
1039
+ "tl.main_axis.grid()\n",
1040
+ "\n",
1041
+ "s = dpl.scatter(x=1,y=0)\n",
1042
+ "s.rotate(start_angle=0,end_angle=360,center=(0,0),duration=60)\n",
1043
+ "a = dpl.axis_track(obj=s,duration=60)\n",
1044
+ "\n",
1045
+ "tl.animate((s,a))\n",
1046
+ "tl.save_video('../_static/animations/axis_track.mp4')"
1047
+ ]
1048
+ },
897
1049
  {
898
1050
  "cell_type": "markdown",
899
1051
  "id": "cfc18431",
@@ -25,6 +25,15 @@
25
25
  "- `svg()`\n",
26
26
  "- `Circle()`\n",
27
27
  "- `fill()`\n",
28
+ "- `Annulus()`\n",
29
+ "- `Arc()`\n",
30
+ "- `Arrow()`\n",
31
+ "- `Ellipse()`\n",
32
+ "- `FancyArrow()`\n",
33
+ "- `Polygon()`\n",
34
+ "- `Rectangle()`\n",
35
+ "- `RegularPolygon()`\n",
36
+ "- `Wedge()`\n",
28
37
  "\n",
29
38
  "Their signature are the same as the [matplotlib ones](https://matplotlib.org).\n",
30
39
  "\n",
@@ -0,0 +1 @@
1
+ __version__ = "0.5.1"