From c4040aedc2feae3492f82ac8889ecc0f39f7c643 Mon Sep 17 00:00:00 2001 From: Davide Gerosa Date: Sat, 13 Jan 2024 15:01:42 +0100 Subject: [PATCH] Sat Jan 13 15:01:42 CET 2024 --- lectures/L08_pytest_pip.ipynb | 25 ++++++++++++++++++------- lectures/mymodule/setup.py | 15 +++++++-------- 2 files changed, 25 insertions(+), 15 deletions(-) diff --git a/lectures/L08_pytest_pip.ipynb b/lectures/L08_pytest_pip.ipynb index 280850a..a6cbf61 100644 --- a/lectures/L08_pytest_pip.ipynb +++ b/lectures/L08_pytest_pip.ipynb @@ -8,19 +8,32 @@ "\n", "*Davide Gerosa (Milano-Bicocca)*\n", "\n", - "**Sources**: Michael Zingale at Stony Brook University: https://sbu-python-class.github.io" + "**Sources**: \n", + " - Michael Zingale at Stony Brook University: https://sbu-python-class.github.io\n", + " - \n" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ - "# Part 1. Share your own package " + "Plan for today:\n", + " \n", + " - Part 1. Package and share your code\n", + " - Part 2. Testing done right\n", + " - Part 3. Find the bottleneck" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Part 1. Package and share your code" ] }, { "cell_type": "code", - "execution_count": 1, + "execution_count": 2, "metadata": {}, "outputs": [], "source": [ @@ -57,7 +70,7 @@ "\n", "## Standalone module\n", "\n", - "Here's a very simply module (lets call it `hello.py`):\n", + "Here's a very simple module (lets call it `hello.py`):\n", "\n", "```python\n", "def hello():\n", @@ -307,8 +320,6 @@ "\n", "https://github.com/dgerosa/scientificcomputing_bicocca_2023/tree/main/lectures/mymodule\n", "\n", - "On your local computer, if you have `git` installed and know how to use it, you can clone the repository. Otherwise go [here](https://github.com/dgerosa/scientificcomputing_bicocca_2023/tree/main), then \"Code\", and \"Download ZIP\".\n", - "\n", "The directory structure appears as:\n", "\n", "```\n", @@ -377,7 +388,7 @@ "from setuptools import setup, find_packages\n", "\n", "setup(name='mymodule',\n", - " description='test module the SciComp class',\n", + " description='test module for the SciComp class',\n", " url='https://github.com/dgerosa',\n", " author='Davide Gerosa',\n", " author_email='davide.gerosa@unimib.it',\n", diff --git a/lectures/mymodule/setup.py b/lectures/mymodule/setup.py index 11dfc9f..06482bb 100644 --- a/lectures/mymodule/setup.py +++ b/lectures/mymodule/setup.py @@ -1,11 +1,10 @@ -from setuptools import find_packages, setup +from setuptools import setup, find_packages setup(name='mymodule', - description='test module for PHY 546', - url='https://github.com/sbu-python-class/mymodule', - author='Michael Zingale', - author_email='michael.zingale@stonybrook.edu', - license='BSD', - version="0.0.1", + description='test module for the SciComp class', + url='https://github.com/dgerosa', + author='Davide Gerosa', + author_email='davide.gerosa@unimib.it', + license='MIT', packages=find_packages(), - install_requires=['numpy', 'matplotlib']) + install_requires=['numpy', 'matplotlib']) \ No newline at end of file