{"id":657,"date":"2025-02-09T14:54:00","date_gmt":"2025-02-09T13:54:00","guid":{"rendered":"https:\/\/noiseonthenet.space\/noise\/?p=657"},"modified":"2025-02-09T15:11:29","modified_gmt":"2025-02-09T14:11:29","slug":"coming-back-down-to-earth","status":"publish","type":"post","link":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/","title":{"rendered":"Coming back down to Earth"},"content":{"rendered":"\n<p class=\"\"><\/p>\n\n\n<p> <img data-recalc-dims=\"1\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?ssl=1\" alt=\"dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg\" \/> Photo by <a href=\"https:\/\/unsplash.com\/@dylandejonge?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash\">Dylan de Jonge<\/a> on <a href=\"https:\/\/unsplash.com\/photos\/brown-pathway-between-green-leaf-plants-9SjCXUq_qSE?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash\">Unsplash<\/a> <\/p>\n<p> Our journey in the galaxy of Python analytics started with a <a href=\"https:\/\/noiseonthenet.space\/noise\/2025\/01\/a-trip-to-jupyter-lab\/\">visit on Jupyter<\/a> where we <a href=\"https:\/\/noiseonthenet.space\/noise\/2025\/01\/meet-the-pandas\/\">met the Pandas<\/a> and started our <a href=\"https:\/\/noiseonthenet.space\/noise\/2025\/02\/data-the-final-frontier\/\">fearless exploration of data<\/a>. <\/p>\n<p> It is sometime useful to leave the colorful interactive environment of Jupyter to create more prosaic standalone python script which are easier to automate or included in a larger project. <\/p>\n<p> It&rsquo;s time to come back to Earth: this won&rsquo;t be a step back, rather it can be an opportunity to start something bigger, like a larger team project or to create an application. <\/p>\n<p> <a id=\"org5de96fe\"><\/a> <\/p>\n<div id=\"outline-container-create-a-script-from-a-jupyter-notebook\" class=\"outline-2\">\n<h2 id=\"create-a-script-from-a-jupyter-notebook\">Create a Script from a Jupyter Notebook<\/h2>\n<div class=\"outline-text-2\" id=\"text-create-a-script-from-a-jupyter-notebook\">\n<p> Sometime it is useful to transform your notebook in an actual script e.g.: <\/p>\n<ul class=\"org-ul\">\n<li>if you want it to be executed automatically (unattended)<\/li>\n<li>if you want to create a module out of it in order to use it in a bigger application<\/li>\n<\/ul>\n<p> <a id=\"org4ecdb8b\"><\/a> <\/p>\n<\/div>\n<div id=\"outline-container-extract-code-from-jupyter\" class=\"outline-3\">\n<h3 id=\"extract-code-from-jupyter\">extract code from Jupyter<\/h3>\n<div class=\"outline-text-3\" id=\"text-extract-code-from-jupyter\">\n<p> Jupyter has a very wide range of formats to export the content of a notebook; some of them are a graphical export (e.g. html or pdf &#x2013; this requires a latex installation) or textual export (ascii, rtf), etc. <\/p>\n<p> To start creating a python script from your notebook, open it into Jupyter, then <\/p>\n<ol class=\"org-ol\">\n<li>from the File menu select <code>save and export notebook as<\/code><\/li>\n<li>from the submenu select <code>Executable script<\/code> this will save a file in your Download directory named with the title of your notebook, but with .py extension<\/li>\n<\/ol>\n<p> You can now open this file with your favorite code editor; here is what you will see: <\/p>\n<ul class=\"org-ul\">\n<li>before every cell there will be a comment with the cell execution number<\/li>\n<li>every code cell will be copied in an individual block of commands<\/li>\n<li>markdown cells and raw cells will be presented as comments<\/li>\n<li>output will be removed<\/li>\n<\/ul>\n<p> In the following sections I will list some cleanup actions which will help you transform this script into a more manageable piece of code <\/p>\n<p> <a id=\"org2768e33\"><\/a> <\/p>\n<\/div>\n<\/div>\n<div id=\"outline-container-manage-magic-code\" class=\"outline-3\">\n<h3 id=\"manage-magic-code\">manage magic code<\/h3>\n<div class=\"outline-text-3\" id=\"text-manage-magic-code\">\n<p> magic code is translated into the equivalent python call e.g. <\/p>\n<p><em><\/em><\/p>\n<pre class=\"example\" id=\"nil\">\n?sum\n<\/pre>\n<p> becomes <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\">get_ipython().run_line_magic(<span style=\"color: #a6e3a1;\">'pinfo'<\/span>, <span style=\"color: #a6e3a1;\">'sum'<\/span>)\n<\/pre>\n<\/div>\n<p> most of the time you may want to get rid of all of this kind of code as some functionalities (e.g. accessing documentation) are intended only for interactive usage within a jupyter notebook. <\/p>\n<p> Other functionalities (e.g. timing your cell execution) may be better managed with other libraries. <\/p>\n<p> <a id=\"org23a7b5d\"><\/a> <\/p>\n<\/div>\n<\/div>\n<div id=\"outline-container-add-code-to-save-tables\" class=\"outline-3\">\n<h3 id=\"add-code-to-save-tables\">add code to save tables<\/h3>\n<div class=\"outline-text-3\" id=\"text-add-code-to-save-tables\">\n<p> Jupyter conveniently shows pandas =DataFrame=s as tables; you may want to extract these results into files. <\/p>\n<p> To access these tables from a script you can save them into files <\/p>\n<\/div>\n<div id=\"outline-container-small-size\" class=\"outline-4\">\n<h4 id=\"small-size\">small size<\/h4>\n<div class=\"outline-text-4\" id=\"text-small-size\">\n<p> If your table are small you may be willing to save them in some simple format: <\/p>\n<ul class=\"org-ul\">\n<li>\n<p> csv using <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\">  df.to_csv(<span style=\"color: #a6e3a1;\">\"my_file.csv\"<\/span>)\n<\/pre>\n<\/div>\n<\/li>\n<li>\n<p> <a href=\"https:\/\/pandas.pydata.org\/pandas-docs\/stable\/reference\/api\/pandas.DataFrame.to_excel.html\">Microsoft Excel<\/a> using <code>openpyxl<\/code> <a href=\"https:\/\/openpyxl.readthedocs.io\/en\/stable\/tutorial.html\">optional library<\/a> <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\">  df.to_excel(<span style=\"color: #a6e3a1;\">\"my_file.xlsx\"<\/span>)\n<\/pre>\n<\/div>\n<\/li>\n<\/ul>\n<\/div>\n<\/div>\n<div id=\"outline-container-large-size\" class=\"outline-4\">\n<h4 id=\"large-size\">large size<\/h4>\n<div class=\"outline-text-4\" id=\"text-large-size\">\n<p> For larger tables or more complex tasks binary formats may help. <\/p>\n<ul class=\"org-ul\">\n<li>\n<p> <a href=\"https:\/\/parquet.apache.org\/\">Apache Parquet<\/a> is a columnar binary format ideal for large data collections and high performance computation; it requires some optional library e.g. <a href=\"https:\/\/arrow.apache.org\/docs\/python\/index.html\">pyarrow<\/a> see <a href=\"https:\/\/pandas.pydata.org\/pandas-docs\/stable\/reference\/api\/pandas.DataFrame.to_parquet.html\">documentation<\/a> <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\">  df.to_parquet(<span style=\"color: #a6e3a1;\">\"my_file.pqt\"<\/span>)\n<\/pre>\n<\/div>\n<\/li>\n<li><a href=\"https:\/\/www.hdfgroup.org\/solutions\/hdf5\/\">hdf5<\/a> is a binary format which can contain multiple tables in a single file (see <a href=\"https:\/\/pandas.pydata.org\/pandas-docs\/stable\/reference\/api\/pandas.DataFrame.to_hdf.html\">documentation<\/a> ) <code>python   df.to_hdf(\"my_file.pqt\")<\/code><\/li>\n<\/ul>\n<\/div>\n<\/div>\n<div id=\"outline-container-databases\" class=\"outline-4\">\n<h4 id=\"databases\">databases<\/h4>\n<div class=\"outline-text-4\" id=\"text-databases\">\n<p> Pandas has a simple mapping <a href=\"https:\/\/pandas.pydata.org\/docs\/reference\/api\/pandas.DataFrame.to_sql.html\">from tables to data frames<\/a> which requires <a href=\"https:\/\/docs.sqlalchemy.org\/en\/20\/\">sqlalchemy<\/a> and a driver of the database. Python basic distribution include <a href=\"https:\/\/docs.python.org\/3\/library\/sqlite3.html\">sqlite<\/a> but many more are available as optional packages <code>python   df.to_sql(name<\/code>&rsquo;my_table&rsquo;, con=engine)= <\/p>\n<p> <a id=\"org73ed4dd\"><\/a> <\/p>\n<\/div>\n<\/div>\n<\/div>\n<div id=\"outline-container-add-code-to-save-figures\" class=\"outline-3\">\n<h3 id=\"add-code-to-save-figures\">add code to save figures<\/h3>\n<div class=\"outline-text-3\" id=\"text-add-code-to-save-figures\">\n<p> the following example works for <code>matplotlib<\/code> and any library based on it, like <code>seaborn<\/code>. <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\"><span style=\"color: #cba6f7;\">import<\/span> pandas <span style=\"color: #cba6f7;\">as<\/span> pd\n<span style=\"color: #cba6f7;\">import<\/span> matplotlib.pyplot <span style=\"color: #cba6f7;\">as<\/span> plt\n<span style=\"color: #cba6f7;\">import<\/span> seaborn <span style=\"color: #cba6f7;\">as<\/span> sns\n<span style=\"color: #cdd6f4;\">california<\/span> <span style=\"color: #89dceb;\">=<\/span> pd.read_csv(<span style=\"color: #a6e3a1;\">\"california_pb_2023.csv\"<\/span>)\n<\/pre>\n<\/div>\n<p> <a id=\"org2044910\"><\/a> The simplest way to save an image is to <\/p>\n<ol class=\"org-ol\">\n<li>store the <code>Axis<\/code> object created into some variable<\/li>\n<li>reach the <code>Figure<\/code> object from the <code>.figure<\/code> attribute<\/li>\n<li>use the <code>.savefig()<\/code> <a href=\"https:\/\/matplotlib.org\/stable\/api\/_as_gen\/matplotlib.pyplot.savefig.html\">method<\/a><\/li>\n<\/ol>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\"><span style=\"color: #cdd6f4;\">ax<\/span> <span style=\"color: #89dceb;\">=<\/span> sns.histplot(california,x<span style=\"color: #89dceb;\">=<\/span><span style=\"color: #a6e3a1;\">\"Daily Mean Pb Concentration\"<\/span>)\nax.figure.savefig(<span style=\"color: #a6e3a1;\">\"pb_2003.png\"<\/span>)\n<\/pre>\n<\/div>\n<div id=\"orgdaaabb4\" class=\"figure\">\n<p><img data-recalc-dims=\"1\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/1e179c2227cfbdf703d241d0bb9385b826510526-1.png?ssl=1\" alt=\"1e179c2227cfbdf703d241d0bb9385b826510526.png\" \/> <\/p>\n<\/p>\n<\/div>\n<p> <a id=\"org8e4ea46\"><\/a> A more complex sequence is required when working with <a href=\"https:\/\/matplotlib.org\/stable\/gallery\/subplots_axes_and_figures\/subplots_demo.html\">multiple plots<\/a> either stacked or overlapped. <\/p>\n<p> In this case the <code>pd.subplot()<\/code> function creates multiple charts (axis) in a single figure <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-python\" id=\"nil\"><span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">this code is general: two charts in a single row<\/span>\nfig, (<span style=\"color: #cdd6f4;\">ax1<\/span>, <span style=\"color: #cdd6f4;\">ax2<\/span>) <span style=\"color: #89dceb;\">=<\/span> plt.subplots(<span style=\"color: #fab387;\">1<\/span>, <span style=\"color: #fab387;\">2<\/span>)\nfig.suptitle(<span style=\"color: #a6e3a1;\">'Horizontally stacked subplots'<\/span>)\n\n<span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">this code is specific for this function<\/span>\n<span style=\"color: #cba6f7;\">from<\/span> scipy <span style=\"color: #cba6f7;\">import<\/span> stats\nstats.probplot(california[<span style=\"color: #a6e3a1;\">\"Daily Mean Pb Concentration\"<\/span>], plot<span style=\"color: #89dceb;\">=<\/span>ax1)\nstats.probplot(california[<span style=\"color: #a6e3a1;\">\"Daily Mean Pb Concentration\"<\/span>], plot<span style=\"color: #89dceb;\">=<\/span>ax2,dist<span style=\"color: #89dceb;\">=<\/span>stats.distributions.lognorm(s<span style=\"color: #89dceb;\">=<\/span><span style=\"color: #fab387;\">1<\/span>))\n\nfig.savefig(<span style=\"color: #a6e3a1;\">\"probplots.png\"<\/span>)\n<\/pre>\n<\/div>\n<div id=\"orgf0a0444\" class=\"figure\">\n<p><img data-recalc-dims=\"1\" decoding=\"async\" src=\"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/0a2e775b9b7dabcdc191e7fcca8c978fccd8992d.png?ssl=1\" alt=\"0a2e775b9b7dabcdc191e7fcca8c978fccd8992d.png\" \/> <\/p>\n<\/p>\n<\/div>\n<p> <a id=\"org3820e9d\"><\/a> <\/p>\n<\/div>\n<\/div>\n<div id=\"outline-container-clean-up-the-code\" class=\"outline-3\">\n<h3 id=\"clean-up-the-code\">clean up the code<\/h3>\n<div class=\"outline-text-3\" id=\"text-clean-up-the-code\">\n<p> The following suggestions holds for any python script and are not strictly required for the execution. <\/p>\n<ul class=\"org-ul\">\n<li>move all <code>import<\/code> statements at the beginning of the file<\/li>\n<li>organize the code in functions and classes; possibly add type annotations<\/li>\n<li>create a single entry point at the bottom of the code with the usual <code>python   if __name__ =<\/code> &ldquo;<u><u>main<\/u><\/u>&rdquo;:       main()=<\/li>\n<li>add command line options management using libraries like <code>optparse<\/code> <a href=\"https:\/\/docs.python.org\/3\/library\/optparse.html\">(see here)<\/a><\/li>\n<li>separate data and configuration from code: libraries like <code>toml<\/code> <a href=\"https:\/\/github.com\/uiri\/toml\">(see here)<\/a> can help reading configuration files<\/li>\n<li>transform absolute paths into relative paths<\/li>\n<li>consider using pyproject.html to <a href=\"https:\/\/packaging.python.org\/en\/latest\/guides\/writing-pyproject-toml\/\">collect dependencies and constraints<\/a><\/li>\n<li>consider using a linter (e.g. <a href=\"https:\/\/www.pylint.org\/\">pylint<\/a> or <a href=\"https:\/\/docs.astral.sh\/ruff\/\">ruff<\/a>) to evaluate code inconsistencies<\/li>\n<li>create unit tests to verify your functions individually; <code>pytest<\/code> helps in this <a href=\"https:\/\/docs.pytest.org\/en\/stable\/\">task<\/a><\/li>\n<li>add documentation per each function or class as well as a module doc string<\/li>\n<li>use a code formatter to keep your style consistent (e.g. <a href=\"https:\/\/black.readthedocs.io\/en\/stable\/\">black<\/a>)<\/li>\n<\/ul>\n<p> <a id=\"org27c415a\"><\/a> <\/p>\n<\/div>\n<\/div>\n<div id=\"outline-container-add-shell-script-to-launch-the-code\" class=\"outline-3\">\n<h3 id=\"add-shell-script-to-launch-the-code\">add shell script to launch the code<\/h3>\n<div class=\"outline-text-3\" id=\"text-add-shell-script-to-launch-the-code\">\n<p> I find it very convenient to have a shell script taking care of <\/p>\n<ul class=\"org-ul\">\n<li>setting up the working directory of the process properly<\/li>\n<li>activate any virtual environment as needed<\/li>\n<li>fix the environment variables<\/li>\n<\/ul>\n<p> e.g. <\/p>\n<div class=\"org-src-container\">\n<label class=\"org-src-name\"><em><\/em><\/label><\/p>\n<pre class=\"src src-sh\" id=\"nil\"><span style=\"color: #6c7086;\">#<\/span><span style=\"color: #6c7086;\">!\/bin\/<\/span><span style=\"color: #cba6f7;\">bash<\/span>\n\n<span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">change the process directory to this one<\/span>\n<span style=\"color: #f9e2af;\">cd<\/span> $<span style=\"color: #f38ba8;\">(<\/span><span style=\"color: #fa8072;\">dirname $0<\/span><span style=\"color: #f38ba8;\">)<\/span>\n\n<span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">activate a local virtual environment<\/span>\n<span style=\"color: #f38ba8;\">source<\/span> .venv\/bin\/activate\n\n<span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">set up some environment variables<\/span>\n<span style=\"color: #f38ba8;\">export<\/span> <span style=\"color: #cdd6f4;\">PYTHONPATH<\/span>=$<span style=\"color: #f38ba8;\">(<\/span><span style=\"color: #fa8072;\">pwd<\/span><span style=\"color: #f38ba8;\">)<\/span>\n\n<span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">launch the application<\/span>\n<span style=\"color: #6c7086;\"># <\/span><span style=\"color: #6c7086;\">forwards all command line arguments<\/span>\npython -m myapp $<span style=\"color: #cdd6f4;\">@<\/span>\n<\/pre>\n<\/div>\n<p> <a id=\"orgb3c836e\"><\/a> <\/p>\n<\/div>\n<\/div>\n<\/div>\n<div id=\"outline-container-exercise\" class=\"outline-2\">\n<h2 id=\"exercise\">Exercise<\/h2>\n<div class=\"outline-text-2\" id=\"text-exercise\">\n<p> transform the notebook you created and edited in the previous section (Exploratory Data Analysis) in an executable script <\/p>\n<\/div>\n<\/div>","protected":false},"excerpt":{"rendered":"Our journey in the galaxy of Python analytics started with a visit on Jupyter\nwhere we met the Pandas and started our fearless exploration of data.\n\nIt is sometime useful to leave the colorful interactive environment of Jupyter\nto create more prosaic standalone python scripts which are easier to automate or\nincluded in a larger project.","protected":false},"author":1,"featured_media":654,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"nf_dc_page":"","inline_featured_image":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4],"tags":[7],"class_list":["post-657","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-language-learning","tag-python"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Coming back down to Earth - Noise On The Net<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Coming back down to Earth - Noise On The Net\" \/>\n<meta property=\"og:description\" content=\"Our journey in the galaxy of Python analytics started with a visit on Jupyter where we met the Pandas and started our fearless exploration of data. It is sometime useful to leave the colorful interactive environment of Jupyter to create more prosaic standalone python scripts which are easier to automate or included in a larger project.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/\" \/>\n<meta property=\"og:site_name\" content=\"Noise On The Net\" \/>\n<meta property=\"article:published_time\" content=\"2025-02-09T13:54:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-02-09T14:11:29+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"800\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"marco.p.v.vezzoli\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"marco.p.v.vezzoli\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/\"},\"author\":{\"name\":\"marco.p.v.vezzoli\",\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/#\\\/schema\\\/person\\\/88c3a70f2b23480197bc61d6e1e2e982\"},\"headline\":\"Coming back down to Earth\",\"datePublished\":\"2025-02-09T13:54:00+00:00\",\"dateModified\":\"2025-02-09T14:11:29+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/\"},\"wordCount\":817,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/#\\\/schema\\\/person\\\/88c3a70f2b23480197bc61d6e1e2e982\"},\"image\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/noiseonthenet.space\\\/noise\\\/wp-content\\\/uploads\\\/2025\\\/02\\\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1\",\"keywords\":[\"Python\"],\"articleSection\":[\"Language learning\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/\",\"url\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/\",\"name\":\"Coming back down to Earth - Noise On The Net\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/i0.wp.com\\\/noiseonthenet.space\\\/noise\\\/wp-content\\\/uploads\\\/2025\\\/02\\\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1\",\"datePublished\":\"2025-02-09T13:54:00+00:00\",\"dateModified\":\"2025-02-09T14:11:29+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#primaryimage\",\"url\":\"https:\\\/\\\/i0.wp.com\\\/noiseonthenet.space\\\/noise\\\/wp-content\\\/uploads\\\/2025\\\/02\\\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1\",\"contentUrl\":\"https:\\\/\\\/i0.wp.com\\\/noiseonthenet.space\\\/noise\\\/wp-content\\\/uploads\\\/2025\\\/02\\\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1\",\"width\":1200,\"height\":800},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/2025\\\/02\\\/coming-back-down-to-earth\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Coming back down to Earth\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/#website\",\"url\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/\",\"name\":\"Noise On The Net\",\"description\":\"Sharing adventures in code\",\"publisher\":{\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/#\\\/schema\\\/person\\\/88c3a70f2b23480197bc61d6e1e2e982\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/#\\\/schema\\\/person\\\/88c3a70f2b23480197bc61d6e1e2e982\",\"name\":\"marco.p.v.vezzoli\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g\",\"caption\":\"marco.p.v.vezzoli\"},\"logo\":{\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g\"},\"description\":\"Self taught assembler programming at 11 on my C64 (1983). Never stopped since then -- always looking up for curious things in the software development, data science and AI. Linux and FOSS user since 1994. MSc in physics in 1996. Working in large semiconductor companies since 1997 (STM, Micron) developing analytics and full stack web infrastructures, microservices, ML solutions\",\"sameAs\":[\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/in\\\/marco-paolo-valerio-vezzoli-0663835\\\/\"],\"url\":\"https:\\\/\\\/noiseonthenet.space\\\/noise\\\/author\\\/marco-p-v-vezzoli\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Coming back down to Earth - Noise On The Net","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/","og_locale":"en_US","og_type":"article","og_title":"Coming back down to Earth - Noise On The Net","og_description":"Our journey in the galaxy of Python analytics started with a visit on Jupyter where we met the Pandas and started our fearless exploration of data. It is sometime useful to leave the colorful interactive environment of Jupyter to create more prosaic standalone python scripts which are easier to automate or included in a larger project.","og_url":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/","og_site_name":"Noise On The Net","article_published_time":"2025-02-09T13:54:00+00:00","article_modified_time":"2025-02-09T14:11:29+00:00","og_image":[{"width":1200,"height":800,"url":"https:\/\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg","type":"image\/jpeg"}],"author":"marco.p.v.vezzoli","twitter_card":"summary_large_image","twitter_misc":{"Written by":"marco.p.v.vezzoli","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#article","isPartOf":{"@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/"},"author":{"name":"marco.p.v.vezzoli","@id":"https:\/\/noiseonthenet.space\/noise\/#\/schema\/person\/88c3a70f2b23480197bc61d6e1e2e982"},"headline":"Coming back down to Earth","datePublished":"2025-02-09T13:54:00+00:00","dateModified":"2025-02-09T14:11:29+00:00","mainEntityOfPage":{"@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/"},"wordCount":817,"commentCount":0,"publisher":{"@id":"https:\/\/noiseonthenet.space\/noise\/#\/schema\/person\/88c3a70f2b23480197bc61d6e1e2e982"},"image":{"@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1","keywords":["Python"],"articleSection":["Language learning"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/","url":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/","name":"Coming back down to Earth - Noise On The Net","isPartOf":{"@id":"https:\/\/noiseonthenet.space\/noise\/#website"},"primaryImageOfPage":{"@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#primaryimage"},"image":{"@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1","datePublished":"2025-02-09T13:54:00+00:00","dateModified":"2025-02-09T14:11:29+00:00","breadcrumb":{"@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#primaryimage","url":"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1","contentUrl":"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1","width":1200,"height":800},{"@type":"BreadcrumbList","@id":"https:\/\/noiseonthenet.space\/noise\/2025\/02\/coming-back-down-to-earth\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/noiseonthenet.space\/noise\/"},{"@type":"ListItem","position":2,"name":"Coming back down to Earth"}]},{"@type":"WebSite","@id":"https:\/\/noiseonthenet.space\/noise\/#website","url":"https:\/\/noiseonthenet.space\/noise\/","name":"Noise On The Net","description":"Sharing adventures in code","publisher":{"@id":"https:\/\/noiseonthenet.space\/noise\/#\/schema\/person\/88c3a70f2b23480197bc61d6e1e2e982"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/noiseonthenet.space\/noise\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/noiseonthenet.space\/noise\/#\/schema\/person\/88c3a70f2b23480197bc61d6e1e2e982","name":"marco.p.v.vezzoli","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g","caption":"marco.p.v.vezzoli"},"logo":{"@id":"https:\/\/secure.gravatar.com\/avatar\/b9d9aab1df560bc14d73b0b442198f196ce39e7c7a38df1dc22fec0b97f17da9?s=96&d=mm&r=g"},"description":"Self taught assembler programming at 11 on my C64 (1983). Never stopped since then -- always looking up for curious things in the software development, data science and AI. Linux and FOSS user since 1994. MSc in physics in 1996. Working in large semiconductor companies since 1997 (STM, Micron) developing analytics and full stack web infrastructures, microservices, ML solutions","sameAs":["https:\/\/noiseonthenet.space\/noise\/","https:\/\/www.linkedin.com\/in\/marco-paolo-valerio-vezzoli-0663835\/"],"url":"https:\/\/noiseonthenet.space\/noise\/author\/marco-p-v-vezzoli\/"}]}},"jetpack_featured_media_url":"https:\/\/i0.wp.com\/noiseonthenet.space\/noise\/wp-content\/uploads\/2025\/02\/dylan-de-jonge-9SjCXUq_qSE-unsplash.jpg?fit=1200%2C800&ssl=1","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/pdDUZ5-aB","jetpack-related-posts":[],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/posts\/657","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/comments?post=657"}],"version-history":[{"count":4,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/posts\/657\/revisions"}],"predecessor-version":[{"id":661,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/posts\/657\/revisions\/661"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/media\/654"}],"wp:attachment":[{"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/media?parent=657"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/categories?post=657"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/noiseonthenet.space\/noise\/wp-json\/wp\/v2\/tags?post=657"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}