Skip to content

Latest commit

 

History

History
24 lines (15 loc) · 1.07 KB

File metadata and controls

24 lines (15 loc) · 1.07 KB

Baltika-arithmetic

Example

Make calculations with favourite beer

Input is the expression like in example below, output is image with this calculated expression presented as bottles of beer. Use notebook or script. Simple arithmetic but huge potential. Trey work only with pics directory. You can make multiplication, division, subtraction and addition (* / - + respectively).

Required libraries

  • PIL
  • numpy
  • matplotlib

Arguments for script

-s, --string STRING expression to calculate;

-o, --out_file FILE to save image in png format;

-w, --with_calc with this option expression will be calculated if this is possiple (only true expressions don't cause an error); without the option only depict numbers and signs (useful in date visualisation or similar);

Example of expression string - '1+9/3'. Other examples is in notebook.

Example2