From 323bf0d9104a28d6924b430c0b30df19096c6fef Mon Sep 17 00:00:00 2001 From: VsevolodX <79542055+VsevolodX@users.noreply.github.com> Date: Tue, 26 Mar 2024 17:03:26 -0700 Subject: [PATCH 01/10] update: move materials import to 3 --- ...create_interface_with_min_strain_zsl.ipynb | 79 ++++++++++--------- 1 file changed, 40 insertions(+), 39 deletions(-) diff --git a/other/materials_designer/create_interface_with_min_strain_zsl.ipynb b/other/materials_designer/create_interface_with_min_strain_zsl.ipynb index 7277ddfd..6d195872 100644 --- a/other/materials_designer/create_interface_with_min_strain_zsl.ipynb +++ b/other/materials_designer/create_interface_with_min_strain_zsl.ipynb @@ -10,8 +10,7 @@ "\n", "

Usage

\n", "\n", - "0. Make sure to select Input Materials\n", - "1. Execute \"Run first: ...\" cell below to load Input Materials into the current kernel\n", + "1. Make sure to select Input Materials\n", "2. Set Input Parameters (e.g. `MILLER_INDICES`, `THICKNESS`, `MAX_AREA`) below or use the default values\n", "3. Click \"Run\" > \"Run All Cells\" to run all cells\n", "4. Wait for the run to complete (depending on the area, it can take 1-2 min or more). Scroll down to view cell results.\n", @@ -31,25 +30,6 @@ "3. When the strain matching is finished, the interface with the lowest strain (and the smallest number of atoms) is selected. We create the corresponding supercells and place them at a specified distance from each other (note no shift is performed currently).\n" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "

Run first: load input materials in current kernel

\n" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "from jupyterlite.utils import get_data\n", - "\n", - "# Get the list of input materials and load them into `materials_in` variable\n", - "get_data(\"materials_in\", globals())" - ] - }, { "cell_type": "markdown", "metadata": {}, @@ -143,12 +123,40 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 3. Create interfaces\n", + "## 3. Load and prepare input Materials\n" + ] + }, + { + "cell_type": "code", + "outputs": [], + "source": [ + "from jupyterlite.utils import get_data\n", + "from src.utils import to_pymatgen\n", + "# Get the list of input materials and load them into `materials_in` variable\n", + "get_data(\"materials_in\", globals())\n", + "\n", + "if \"materials_in\" in globals():\n", + " pymatgen_materials = [to_pymatgen(item) for item in materials_in]\n", + "for material in pymatgen_materials:\n", + " print(material, \"\\n\")" + ], + "metadata": { + "collapsed": false + }, + "execution_count": null + }, + { + "cell_type": "markdown", + "source": [ + "## 4. Create interfaces\n", "\n", - "### 3.1. Extract Interfaces and Terminations\n", + "### 4.1. Extract Interfaces and Terminations\n", "\n", "Extract all possible layer/substrate supercell combinations within the maximum area including different terminations." - ] + ], + "metadata": { + "collapsed": false + } }, { "cell_type": "code", @@ -160,13 +168,6 @@ "outputs": [], "source": [ "from src.pymatgen_coherent_interface_builder import CoherentInterfaceBuilder, ZSLGenerator\n", - "from src.utils import to_pymatgen\n", - "\n", - "if \"materials_in\" in globals():\n", - " pymatgen_materials = [to_pymatgen(item) for item in materials_in]\n", - "for material in pymatgen_materials:\n", - " print(material, \"\\n\")\n", - "\n", "\n", "def create_interfaces(settings):\n", " print(\"Creating interfaces...\")\n", @@ -221,7 +222,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 3.2. Print out the interfaces and terminations" + "### 5.2. Print out the interfaces and terminations" ] }, { @@ -239,9 +240,9 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 4. Sort interfaces by strain\n", + "## 5. Sort interfaces by strain\n", "\n", - "### 4.1. Sort all interfaces" + "### 5.1. Sort all interfaces" ] }, { @@ -271,7 +272,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 4.2. Print out interfaces with lowest strain for each termination" + "### 5.2. Print out interfaces with lowest strain for each termination" ] }, { @@ -291,7 +292,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 5. Plot the results\n", + "## 6. Plot the results\n", "\n", "Plot the number of atoms vs strain. Adjust the parameters as needed.\n" ] @@ -367,9 +368,9 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 6. Select the interface to pass outside this kernel\n", + "## 7. Select the interface to pass outside this kernel\n", "\n", - "### 6.1. Select the interface with the desired termination and strain\n", + "### 7.1. Select the interface with the desired termination and strain\n", "\n", "The data in `sorted_interfaces` now contains an object with the following structure:\n", "\n", @@ -409,7 +410,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 6.2. Pass data to the outside runtime\n" + "### 7.2. Pass data to the outside runtime\n" ] }, { From 62428cc03992078cb04730f4b3a8288a72a5811f Mon Sep 17 00:00:00 2001 From: VsevolodX <79542055+VsevolodX@users.noreply.github.com> Date: Tue, 26 Mar 2024 18:53:13 -0700 Subject: [PATCH 02/10] update: adjust notebook 2 --- ...te_interface_with_relaxation_ase_emt.ipynb | 90 ++++++++++--------- 1 file changed, 46 insertions(+), 44 deletions(-) diff --git a/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb b/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb index 5cdd03e4..f58e76cf 100644 --- a/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb +++ b/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb @@ -11,8 +11,7 @@ "\n", "

Usage

\n", "\n", - "0. Make sure to select Input Materials\n", - "1. Execute \"Run first: ...\" cell below to load Input Materials into the current kernel\n", + "1. Make sure to select Input Materials\n", "2. Set Input Parameters (e.g. `THICKNESS`, `MAX_AREA`, `FMAX`) below or use the default values\n", "3. Click \"Run\" > \"Run All\" to run all cells\n", "4. Wait for the run to complete (depending on the parameters it can take a few min or more). Scroll down to view cell results.\n", @@ -29,25 +28,6 @@ "2. The interface with the lowest strain is selected and relaxed using the optimizer selected below (BFGS, by default). The EMT potential is used as an energy calculator.\n" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "

Run first: load input materials in current kernel

\n" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [ - "from jupyterlite.utils import get_data\n", - "\n", - "# Get the list of input materials and load them into `materials_in` variable\n", - "get_data(\"materials_in\", globals())" - ] - }, { "cell_type": "markdown", "metadata": {}, @@ -147,13 +127,45 @@ "await install_packages(\"create_interface_with_min_strain_zsl.ipynb\")" ] }, + { + "cell_type": "markdown", + "source": [ + "## 3. Load and prepare Input Materials" + ], + "metadata": { + "collapsed": false + } + }, + { + "cell_type": "code", + "outputs": [], + "source": [ + "from jupyterlite.utils import get_data\n", + "from pymatgen.analysis.structure_analyzer import SpacegroupAnalyzer\n", + "from src.utils import to_pymatgen\n", + "\n", + "# Get the list of input materials and load them into `materials_in` variable\n", + "get_data(\"materials_in\", globals())\n", + "\n", + "if \"materials_in\" in globals():\n", + " pymatgen_materials = [to_pymatgen(item) for item in materials_in]\n", + " if USE_CONVENTIONAL_CELL: pymatgen_materials = [SpacegroupAnalyzer(item).get_conventional_standard_structure() for\n", + " item in pymatgen_materials]\n", + "\n", + " for material in pymatgen_materials:\n", + " print(material, \"\\n\")" + ], + "metadata": { + "collapsed": false + } + }, { "cell_type": "markdown", "metadata": {}, "source": [ - "## 3. Create interfaces\n", + "## 4. Create interfaces\n", "\n", - "### 3.1. Extract Interfaces and Terminations\n", + "### 4.1. Extract Interfaces and Terminations\n", "\n", "Extract all possible layer/substrate supercell combinations within the maximum area including different terminations.\n" ] @@ -168,16 +180,6 @@ "outputs": [], "source": [ "from src.pymatgen_coherent_interface_builder import CoherentInterfaceBuilder, ZSLGenerator\n", - "from pymatgen.analysis.structure_analyzer import SpacegroupAnalyzer\n", - "from src.utils import to_pymatgen\n", - "\n", - "if \"materials_in\" in globals():\n", - " pymatgen_materials = [to_pymatgen(item) for item in materials_in]\n", - " if USE_CONVENTIONAL_CELL: pymatgen_materials = [SpacegroupAnalyzer(item).get_conventional_standard_structure() for\n", - " item in pymatgen_materials]\n", - "\n", - " for material in pymatgen_materials:\n", - " print(material, \"\\n\")\n", "\n", "\n", "def create_interfaces(settings: dict):\n", @@ -233,7 +235,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 3.2. Print out the interfaces and terminations\n" + "### 4.2. Print out the interfaces and terminations\n" ] }, { @@ -251,9 +253,9 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 4. Sort interfaces by strain\n", + "## 5. Sort interfaces by strain\n", "\n", - "### 4.1. Sort all interfaces\n" + "### 5.1. Sort all interfaces\n" ] }, { @@ -283,7 +285,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 4.2. Print out interfaces with lowest strain for each termination\n" + "### 5.2. Print out interfaces with lowest strain for each termination\n" ] }, { @@ -303,7 +305,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 5. Plot the results\n", + "## 6. Plot the results\n", "\n", "Plot the number of atoms vs strain. Adjust the parameters as needed.\n" ] @@ -379,7 +381,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 6. Select the interface with the desired termination and strain\n", + "## 7. Select the interface with the desired termination and strain\n", "\n", "The data in `sorted_interfaces` now contains an object with the following structure:\n", "\n", @@ -421,9 +423,9 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "## 7. Apply relaxation to the interface\n", + "## 8. Apply relaxation to the interface\n", "\n", - "### 7.1. Apply relaxation to the selected interface with ASE\n", + "### 8.1. Apply relaxation to the selected interface with ASE\n", "\n", "Optimizer is set from the available options in the settings and EMT is used as the energy calculator." ] @@ -516,7 +518,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 7.2. View structure before and after relaxation\n" + "### 8.2. View structure before and after relaxation\n" ] }, { @@ -579,7 +581,7 @@ "collapsed": false }, "source": [ - "### 7.3. Calculate the energy metrics\n", + "### 8.3. Calculate the energy metrics\n", "Calculate the energy metrics for the relaxed interface.\n", "The effective delta energy per area calculation accounts for the energy contribution of each component (substrate and layer) relative to their proportion in the overall interface. \n" ] @@ -675,7 +677,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "### 8. Pass relaxed interface to Materials Designer" + "## 9. Pass relaxed interface to Materials Designer" ] }, { From 2a4a4482148d384d84dd2564f386520371f86ed1 Mon Sep 17 00:00:00 2001 From: VsevolodX <79542055+VsevolodX@users.noreply.github.com> Date: Tue, 26 Mar 2024 18:53:27 -0700 Subject: [PATCH 03/10] update: adjust notebook 1 --- .../create_interface_with_min_strain_zsl.ipynb | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/other/materials_designer/create_interface_with_min_strain_zsl.ipynb b/other/materials_designer/create_interface_with_min_strain_zsl.ipynb index 6d195872..d1113eb6 100644 --- a/other/materials_designer/create_interface_with_min_strain_zsl.ipynb +++ b/other/materials_designer/create_interface_with_min_strain_zsl.ipynb @@ -55,7 +55,9 @@ " \"MATERIAL_INDEX\": 1, # the index of the material in the materials_in list\n", " \"MILLER_INDICES\": (0, 0, 1), # the miller indices of the interfacial plane\n", " \"THICKNESS\": 1, # in layers\n", - "}" + "}\n", + "\n", + "USE_CONVENTIONAL_CELL = True # if True, the surface plane is constructed using miller indices of the conventional cell" ] }, { @@ -131,14 +133,19 @@ "outputs": [], "source": [ "from jupyterlite.utils import get_data\n", + "from pymatgen.analysis.structure_analyzer import SpacegroupAnalyzer\n", "from src.utils import to_pymatgen\n", + "\n", "# Get the list of input materials and load them into `materials_in` variable\n", "get_data(\"materials_in\", globals())\n", "\n", "if \"materials_in\" in globals():\n", " pymatgen_materials = [to_pymatgen(item) for item in materials_in]\n", - "for material in pymatgen_materials:\n", - " print(material, \"\\n\")" + " if USE_CONVENTIONAL_CELL: pymatgen_materials = [SpacegroupAnalyzer(item).get_conventional_standard_structure() for\n", + " item in pymatgen_materials]\n", + "\n", + " for material in pymatgen_materials:\n", + " print(material, \"\\n\")" ], "metadata": { "collapsed": false From 040c6207c770873300c962441b781c2d1e597522 Mon Sep 17 00:00:00 2001 From: VsevolodX <79542055+VsevolodX@users.noreply.github.com> Date: Wed, 27 Mar 2024 16:51:31 -0700 Subject: [PATCH 04/10] update: fix order of dependencies --- other/jupyterlite/utils.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/other/jupyterlite/utils.py b/other/jupyterlite/utils.py index 238eead0..e133816b 100644 --- a/other/jupyterlite/utils.py +++ b/other/jupyterlite/utils.py @@ -69,22 +69,28 @@ async def install_packages(notebook_name, requirements_path="config.yml", verbos requirements_hash = str(hash(json.dumps(requirements))) if os.environ.get("requirements_hash") != requirements_hash: packages_default_common = requirements.get("default", {}).get("packages_common", []) or [] - packages_default_environment_specific = requirements.get("default", {}).get(f"packages_{ENVIRONMENT.value}", []) or [] + packages_default_environment_specific = ( + requirements.get("default", {}).get(f"packages_{ENVIRONMENT.value}", []) or [] + ) notebook_requirements = next( (cfg for cfg in requirements.get("notebooks", []) if cfg.get("name") == notebook_name), None ) if notebook_requirements: packages_notebook_common = notebook_requirements.get("packages_common", []) or [] - packages_notebook_environment_specific= notebook_requirements.get(f"packages_{ENVIRONMENT.value}", []) or [] + packages_notebook_environment_specific = ( + notebook_requirements.get(f"packages_{ENVIRONMENT.value}", []) or [] + ) else: raise ValueError(f"No packages found for notebook {notebook_name}") + # Note: environment specific packages have to be installed first, + # because in Pyodide common packages might depend on them packages = [ - *packages_default_common, *packages_default_environment_specific, - *packages_notebook_common, *packages_notebook_environment_specific, + *packages_default_common, + *packages_notebook_common, ] for pkg in packages: From 04648fb3c5b93a9d8d39b68ba2c3a6c60ad60368 Mon Sep 17 00:00:00 2001 From: VsevolodX <79542055+VsevolodX@users.noreply.github.com> Date: Wed, 27 Mar 2024 17:44:11 -0700 Subject: [PATCH 05/10] update: trnaslate to bottom to allow for multiple layers --- ...create_interface_with_min_strain_zsl.ipynb | 4 + ...te_interface_with_relaxation_ase_emt.ipynb | 250 +++++++++++++++++- other/materials_designer/src/utils.py | 17 ++ 3 files changed, 268 insertions(+), 3 deletions(-) diff --git a/other/materials_designer/create_interface_with_min_strain_zsl.ipynb b/other/materials_designer/create_interface_with_min_strain_zsl.ipynb index d1113eb6..c02b225b 100644 --- a/other/materials_designer/create_interface_with_min_strain_zsl.ipynb +++ b/other/materials_designer/create_interface_with_min_strain_zsl.ipynb @@ -175,7 +175,11 @@ "outputs": [], "source": [ "from src.pymatgen_coherent_interface_builder import CoherentInterfaceBuilder, ZSLGenerator\n", + "from src.utils import translate_to_bottom\n", "\n", + "# Translate the materials to the bottom of the cell to allow for multilayer heterostructures creation\n", + "pymatgen_materials = [translate_to_bottom(item) for item in pymatgen_materials]\n", + " \n", "def create_interfaces(settings):\n", " print(\"Creating interfaces...\")\n", " zsl = ZSLGenerator(\n", diff --git a/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb b/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb index f58e76cf..5f36e7df 100644 --- a/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb +++ b/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb @@ -118,9 +118,250 @@ }, { "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], + "execution_count": 1, + "metadata": { + "ExecuteTime": { + "end_time": "2024-03-28T00:00:14.528456Z", + "start_time": "2024-03-27T23:59:51.381151Z" + } + }, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Requirement already satisfied: pymatgen==2023.9.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (2023.9.10)\n", + "Requirement already satisfied: matplotlib>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.8.3)\n", + "Requirement already satisfied: monty>=3.0.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (2024.2.2)\n", + "Requirement already satisfied: mp-api>=0.27.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.38.0)\n", + "Requirement already satisfied: networkx>=2.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.2.1)\n", + "Requirement already satisfied: numpy>=1.20.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.26.4)\n", + "Requirement already satisfied: palettable>=3.1.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.3.3)\n", + "Requirement already satisfied: pandas in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.5.3)\n", + "Requirement already satisfied: plotly>=4.5.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (5.18.0)\n", + "Requirement already satisfied: pybtex in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.24.0)\n", + "Requirement already satisfied: requests in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (2.31.0)\n", + "Requirement already satisfied: ruamel.yaml>=0.17.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.17.40)\n", + "Requirement already satisfied: scipy>=1.5.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.12.0)\n", + "Requirement already satisfied: spglib>=2.0.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (2.0.2)\n", + "Requirement already satisfied: sympy in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.12)\n", + "Requirement already satisfied: tabulate in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.9.0)\n", + "Requirement already satisfied: tqdm in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (4.66.2)\n", + "Requirement already satisfied: uncertainties>=3.1.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.1.7)\n", + "Requirement already satisfied: joblib in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.3.2)\n", + "Requirement already satisfied: contourpy>=1.0.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (1.2.0)\n", + "Requirement already satisfied: cycler>=0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (0.12.1)\n", + "Requirement already satisfied: fonttools>=4.22.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (4.49.0)\n", + "Requirement already satisfied: kiwisolver>=1.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (1.4.5)\n", + "Requirement already satisfied: packaging>=20.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (23.2)\n", + "Requirement already satisfied: pillow>=8 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (10.2.0)\n", + "Requirement already satisfied: pyparsing>=2.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (2.4.7)\n", + "Requirement already satisfied: python-dateutil>=2.7 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (2.8.2)\n", + "Requirement already satisfied: setuptools in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (69.0.3)\n", + "Requirement already satisfied: msgpack in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.8)\n", + "Requirement already satisfied: maggma>=0.57.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (0.64.0)\n", + "Requirement already satisfied: typing-extensions>=3.7.4.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (4.9.0)\n", + "Requirement already satisfied: emmet-core>=0.69.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (0.69.5)\n", + "Requirement already satisfied: tenacity>=6.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from plotly>=4.5.0->pymatgen==2023.9.10) (8.2.3)\n", + "Requirement already satisfied: charset-normalizer<4,>=2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (3.3.2)\n", + "Requirement already satisfied: idna<4,>=2.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (3.6)\n", + "Requirement already satisfied: urllib3<3,>=1.21.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (2.2.1)\n", + "Requirement already satisfied: certifi>=2017.4.17 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (2024.2.2)\n", + "Requirement already satisfied: ruamel.yaml.clib>=0.2.7 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ruamel.yaml>=0.17.0->pymatgen==2023.9.10) (0.2.8)\n", + "Requirement already satisfied: future in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from uncertainties>=3.1.4->pymatgen==2023.9.10) (1.0.0)\n", + "Requirement already satisfied: pytz>=2020.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas->pymatgen==2023.9.10) (2024.1)\n", + "Requirement already satisfied: PyYAML>=3.01 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pybtex->pymatgen==2023.9.10) (6.0.1)\n", + "Requirement already satisfied: latexcodec>=1.0.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pybtex->pymatgen==2023.9.10) (2.0.1)\n", + "Requirement already satisfied: six in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pybtex->pymatgen==2023.9.10) (1.16.0)\n", + "Requirement already satisfied: mpmath>=0.19 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from sympy->pymatgen==2023.9.10) (1.3.0)\n", + "Requirement already satisfied: pydantic>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (2.6.4)\n", + "Requirement already satisfied: pydantic-settings>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (2.2.1)\n", + "Requirement already satisfied: pydantic-core>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (2.16.3)\n", + "Requirement already satisfied: pymongo>=4.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.6.2)\n", + "Requirement already satisfied: mongomock>=3.10.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.1.2)\n", + "Requirement already satisfied: pydash>=4.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (7.0.7)\n", + "Requirement already satisfied: jsonschema>=3.1.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.21.1)\n", + "Requirement already satisfied: mongogrant>=0.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.3.3)\n", + "Requirement already satisfied: aioitertools>=0.5.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.11.0)\n", + "Requirement already satisfied: fastapi>=0.42.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.110.0)\n", + "Requirement already satisfied: pyzmq>=24.0.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (25.1.2)\n", + "Requirement already satisfied: dnspython>=1.16.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.6.1)\n", + "Requirement already satisfied: sshtunnel>=0.1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.4.0)\n", + "Requirement already satisfied: orjson>=3.9.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.9.15)\n", + "Requirement already satisfied: boto3>=1.20.41 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.34.71)\n", + "Requirement already satisfied: uvicorn>=0.18.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.29.0)\n", + "Requirement already satisfied: botocore<1.35.0,>=1.34.71 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from boto3>=1.20.41->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.34.71)\n", + "Requirement already satisfied: jmespath<2.0.0,>=0.7.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from boto3>=1.20.41->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.1)\n", + "Requirement already satisfied: s3transfer<0.11.0,>=0.10.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from boto3>=1.20.41->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.10.1)\n", + "Requirement already satisfied: starlette<0.37.0,>=0.36.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from fastapi>=0.42.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.36.3)\n", + "Requirement already satisfied: attrs>=22.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (23.2.0)\n", + "Requirement already satisfied: jsonschema-specifications>=2023.03.6 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2023.12.1)\n", + "Requirement already satisfied: referencing>=0.28.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.33.0)\n", + "Requirement already satisfied: rpds-py>=0.7.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.18.0)\n", + "Requirement already satisfied: Click in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (8.1.7)\n", + "Requirement already satisfied: Flask>=1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.0.2)\n", + "Requirement already satisfied: sentinels in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mongomock>=3.10.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.0)\n", + "Requirement already satisfied: annotated-types>=0.4.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pydantic>=2.0->emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (0.6.0)\n", + "Requirement already satisfied: python-dotenv>=0.21.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pydantic-settings>=2.0->emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.1)\n", + "Requirement already satisfied: paramiko>=2.7.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.4.0)\n", + "Requirement already satisfied: h11>=0.8 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from uvicorn>=0.18.3->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.14.0)\n", + "Requirement already satisfied: Werkzeug>=3.0.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.0.1)\n", + "Requirement already satisfied: Jinja2>=3.1.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.1.3)\n", + "Requirement already satisfied: itsdangerous>=2.1.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.1.2)\n", + "Requirement already satisfied: blinker>=1.6.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.7.0)\n", + "Requirement already satisfied: bcrypt>=3.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.1.2)\n", + "Requirement already satisfied: cryptography>=3.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (42.0.5)\n", + "Requirement already satisfied: pynacl>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.5.0)\n", + "Requirement already satisfied: anyio<5,>=3.4.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from starlette<0.37.0,>=0.36.3->fastapi>=0.42.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.3.0)\n", + "Requirement already satisfied: sniffio>=1.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from anyio<5,>=3.4.0->starlette<0.37.0,>=0.36.3->fastapi>=0.42.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.3.0)\n", + "Requirement already satisfied: cffi>=1.12 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from cryptography>=3.3->paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.16.0)\n", + "Requirement already satisfied: MarkupSafe>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Jinja2>=3.1.2->Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.1.5)\n", + "Requirement already satisfied: pycparser in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from cffi>=1.12->cryptography>=3.3->paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.21)\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" + ] + }, + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Installed pymatgen==2023.9.10\n", + "Requirement already satisfied: ase==3.22.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (3.22.1)\n", + "Requirement already satisfied: matplotlib>=3.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ase==3.22.1) (3.8.3)\n", + "Requirement already satisfied: numpy>=1.15.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ase==3.22.1) (1.26.4)\n", + "Requirement already satisfied: scipy>=1.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ase==3.22.1) (1.12.0)\n", + "Requirement already satisfied: contourpy>=1.0.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (1.2.0)\n", + "Requirement already satisfied: cycler>=0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (0.12.1)\n", + "Requirement already satisfied: fonttools>=4.22.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (4.49.0)\n", + "Requirement already satisfied: kiwisolver>=1.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (1.4.5)\n", + "Requirement already satisfied: packaging>=20.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (23.2)\n", + "Requirement already satisfied: pillow>=8 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (10.2.0)\n", + "Requirement already satisfied: pyparsing>=2.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (2.4.7)\n", + "Requirement already satisfied: python-dateutil>=2.7 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (2.8.2)\n", + "Requirement already satisfied: six>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from python-dateutil>=2.7->matplotlib>=3.1.0->ase==3.22.1) (1.16.0)\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" + ] + }, + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Installed ase==3.22.1\n", + "Requirement already satisfied: pandas==1.5.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (1.5.3)\n", + "Requirement already satisfied: python-dateutil>=2.8.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas==1.5.3) (2.8.2)\n", + "Requirement already satisfied: pytz>=2020.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas==1.5.3) (2024.1)\n", + "Requirement already satisfied: numpy>=1.21.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas==1.5.3) (1.26.4)\n", + "Requirement already satisfied: six>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from python-dateutil>=2.8.1->pandas==1.5.3) (1.16.0)\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" + ] + }, + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Installed pandas==1.5.3\n", + "Requirement already satisfied: ipywidgets in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (8.1.2)\n", + "Requirement already satisfied: comm>=0.1.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (0.2.1)\n", + "Requirement already satisfied: ipython>=6.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (8.22.1)\n", + "Requirement already satisfied: traitlets>=4.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (5.14.1)\n", + "Requirement already satisfied: widgetsnbextension~=4.0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (4.0.10)\n", + "Requirement already satisfied: jupyterlab-widgets~=3.0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (3.0.10)\n", + "Requirement already satisfied: decorator in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (5.1.1)\n", + "Requirement already satisfied: jedi>=0.16 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (0.19.1)\n", + "Requirement already satisfied: matplotlib-inline in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (0.1.6)\n", + "Requirement already satisfied: prompt-toolkit<3.1.0,>=3.0.41 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (3.0.43)\n", + "Requirement already satisfied: pygments>=2.4.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (2.17.2)\n", + "Requirement already satisfied: stack-data in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (0.6.3)\n", + "Requirement already satisfied: pexpect>4.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (4.9.0)\n", + "Requirement already satisfied: parso<0.9.0,>=0.8.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jedi>=0.16->ipython>=6.1.0->ipywidgets) (0.8.3)\n", + "Requirement already satisfied: ptyprocess>=0.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pexpect>4.3->ipython>=6.1.0->ipywidgets) (0.7.0)\n", + "Requirement already satisfied: wcwidth in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from prompt-toolkit<3.1.0,>=3.0.41->ipython>=6.1.0->ipywidgets) (0.2.13)\n", + "Requirement already satisfied: executing>=1.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from stack-data->ipython>=6.1.0->ipywidgets) (2.0.1)\n", + "Requirement already satisfied: asttokens>=2.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from stack-data->ipython>=6.1.0->ipywidgets) (2.4.1)\n", + "Requirement already satisfied: pure-eval in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from stack-data->ipython>=6.1.0->ipywidgets) (0.2.2)\n", + "Requirement already satisfied: six>=1.12.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from asttokens>=2.1.0->stack-data->ipython>=6.1.0->ipywidgets) (1.16.0)\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" + ] + }, + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Installed ipywidgets\n", + "Requirement already satisfied: plotly==5.18 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (5.18.0)\n", + "Requirement already satisfied: tenacity>=6.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from plotly==5.18) (8.2.3)\n", + "Requirement already satisfied: packaging in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from plotly==5.18) (23.2)\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" + ] + }, + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Installed plotly==5.18\n", + "Requirement already satisfied: nbformat>=4.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (5.9.2)\n", + "Requirement already satisfied: fastjsonschema in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (2.19.1)\n", + "Requirement already satisfied: jsonschema>=2.6 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (4.21.1)\n", + "Requirement already satisfied: jupyter-core in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (5.7.1)\n", + "Requirement already satisfied: traitlets>=5.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (5.14.1)\n", + "Requirement already satisfied: attrs>=22.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (23.2.0)\n", + "Requirement already satisfied: jsonschema-specifications>=2023.03.6 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (2023.12.1)\n", + "Requirement already satisfied: referencing>=0.28.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (0.33.0)\n", + "Requirement already satisfied: rpds-py>=0.7.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (0.18.0)\n", + "Requirement already satisfied: platformdirs>=2.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jupyter-core->nbformat>=4.2.0) (4.2.0)\n", + "Installed nbformat>=4.2.0\n", + "Packages installed successfully.\n" + ] + }, + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", + "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" + ] + } + ], "source": [ "from jupyterlite.utils import install_packages\n", "\n", @@ -180,7 +421,10 @@ "outputs": [], "source": [ "from src.pymatgen_coherent_interface_builder import CoherentInterfaceBuilder, ZSLGenerator\n", + "from src.utils import translate_to_bottom\n", "\n", + "# Translate the materials to the bottom of the cell to allow for multilayer heterostructures creation\n", + "pymatgen_materials = [translate_to_bottom(item) for item in pymatgen_materials]\n", "\n", "def create_interfaces(settings: dict):\n", " print(\"Creating interfaces...\")\n", diff --git a/other/materials_designer/src/utils.py b/other/materials_designer/src/utils.py index 13973502..5bef131e 100644 --- a/other/materials_designer/src/utils.py +++ b/other/materials_designer/src/utils.py @@ -348,3 +348,20 @@ def from_ase(atoms: Atoms): structure = ase_to_pymatgen(atoms) material = from_pymatgen(structure) return material + + +def translate_to_bottom(structure): + """ + Translate the structure to the bottom of the cell. + Args: + structure (Structure): The pymatgen Structure object to translate. + + Returns: + Structure: The translated pymatgen Structure object. + """ + min_c = min(site.c for site in structure) + translation_vector = [0, 0, -min_c] + translated_structure = structure.copy() + for site in translated_structure: + site.coords += translation_vector + return translated_structure From f68e612d4182d2997d359fe7e23fe2ccb4e22f85 Mon Sep 17 00:00:00 2001 From: VsevolodX <79542055+VsevolodX@users.noreply.github.com> Date: Wed, 27 Mar 2024 17:44:57 -0700 Subject: [PATCH 06/10] chore: clear outputs --- ...te_interface_with_relaxation_ase_emt.ipynb | 247 +----------------- 1 file changed, 3 insertions(+), 244 deletions(-) diff --git a/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb b/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb index 5f36e7df..8f8f5474 100644 --- a/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb +++ b/other/materials_designer/create_interface_with_relaxation_ase_emt.ipynb @@ -118,250 +118,9 @@ }, { "cell_type": "code", - "execution_count": 1, - "metadata": { - "ExecuteTime": { - "end_time": "2024-03-28T00:00:14.528456Z", - "start_time": "2024-03-27T23:59:51.381151Z" - } - }, - "outputs": [ - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Requirement already satisfied: pymatgen==2023.9.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (2023.9.10)\n", - "Requirement already satisfied: matplotlib>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.8.3)\n", - "Requirement already satisfied: monty>=3.0.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (2024.2.2)\n", - "Requirement already satisfied: mp-api>=0.27.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.38.0)\n", - "Requirement already satisfied: networkx>=2.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.2.1)\n", - "Requirement already satisfied: numpy>=1.20.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.26.4)\n", - "Requirement already satisfied: palettable>=3.1.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.3.3)\n", - "Requirement already satisfied: pandas in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.5.3)\n", - "Requirement already satisfied: plotly>=4.5.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (5.18.0)\n", - "Requirement already satisfied: pybtex in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.24.0)\n", - "Requirement already satisfied: requests in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (2.31.0)\n", - "Requirement already satisfied: ruamel.yaml>=0.17.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.17.40)\n", - "Requirement already satisfied: scipy>=1.5.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.12.0)\n", - "Requirement already satisfied: spglib>=2.0.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (2.0.2)\n", - "Requirement already satisfied: sympy in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.12)\n", - "Requirement already satisfied: tabulate in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (0.9.0)\n", - "Requirement already satisfied: tqdm in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (4.66.2)\n", - "Requirement already satisfied: uncertainties>=3.1.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (3.1.7)\n", - "Requirement already satisfied: joblib in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pymatgen==2023.9.10) (1.3.2)\n", - "Requirement already satisfied: contourpy>=1.0.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (1.2.0)\n", - "Requirement already satisfied: cycler>=0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (0.12.1)\n", - "Requirement already satisfied: fonttools>=4.22.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (4.49.0)\n", - "Requirement already satisfied: kiwisolver>=1.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (1.4.5)\n", - "Requirement already satisfied: packaging>=20.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (23.2)\n", - "Requirement already satisfied: pillow>=8 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (10.2.0)\n", - "Requirement already satisfied: pyparsing>=2.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (2.4.7)\n", - "Requirement already satisfied: python-dateutil>=2.7 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=1.5->pymatgen==2023.9.10) (2.8.2)\n", - "Requirement already satisfied: setuptools in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (69.0.3)\n", - "Requirement already satisfied: msgpack in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.8)\n", - "Requirement already satisfied: maggma>=0.57.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (0.64.0)\n", - "Requirement already satisfied: typing-extensions>=3.7.4.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (4.9.0)\n", - "Requirement already satisfied: emmet-core>=0.69.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mp-api>=0.27.3->pymatgen==2023.9.10) (0.69.5)\n", - "Requirement already satisfied: tenacity>=6.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from plotly>=4.5.0->pymatgen==2023.9.10) (8.2.3)\n", - "Requirement already satisfied: charset-normalizer<4,>=2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (3.3.2)\n", - "Requirement already satisfied: idna<4,>=2.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (3.6)\n", - "Requirement already satisfied: urllib3<3,>=1.21.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (2.2.1)\n", - "Requirement already satisfied: certifi>=2017.4.17 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from requests->pymatgen==2023.9.10) (2024.2.2)\n", - "Requirement already satisfied: ruamel.yaml.clib>=0.2.7 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ruamel.yaml>=0.17.0->pymatgen==2023.9.10) (0.2.8)\n", - "Requirement already satisfied: future in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from uncertainties>=3.1.4->pymatgen==2023.9.10) (1.0.0)\n", - "Requirement already satisfied: pytz>=2020.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas->pymatgen==2023.9.10) (2024.1)\n", - "Requirement already satisfied: PyYAML>=3.01 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pybtex->pymatgen==2023.9.10) (6.0.1)\n", - "Requirement already satisfied: latexcodec>=1.0.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pybtex->pymatgen==2023.9.10) (2.0.1)\n", - "Requirement already satisfied: six in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pybtex->pymatgen==2023.9.10) (1.16.0)\n", - "Requirement already satisfied: mpmath>=0.19 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from sympy->pymatgen==2023.9.10) (1.3.0)\n", - "Requirement already satisfied: pydantic>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (2.6.4)\n", - "Requirement already satisfied: pydantic-settings>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (2.2.1)\n", - "Requirement already satisfied: pydantic-core>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (2.16.3)\n", - "Requirement already satisfied: pymongo>=4.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.6.2)\n", - "Requirement already satisfied: mongomock>=3.10.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.1.2)\n", - "Requirement already satisfied: pydash>=4.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (7.0.7)\n", - "Requirement already satisfied: jsonschema>=3.1.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.21.1)\n", - "Requirement already satisfied: mongogrant>=0.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.3.3)\n", - "Requirement already satisfied: aioitertools>=0.5.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.11.0)\n", - "Requirement already satisfied: fastapi>=0.42.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.110.0)\n", - "Requirement already satisfied: pyzmq>=24.0.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (25.1.2)\n", - "Requirement already satisfied: dnspython>=1.16.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.6.1)\n", - "Requirement already satisfied: sshtunnel>=0.1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.4.0)\n", - "Requirement already satisfied: orjson>=3.9.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.9.15)\n", - "Requirement already satisfied: boto3>=1.20.41 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.34.71)\n", - "Requirement already satisfied: uvicorn>=0.18.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.29.0)\n", - "Requirement already satisfied: botocore<1.35.0,>=1.34.71 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from boto3>=1.20.41->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.34.71)\n", - "Requirement already satisfied: jmespath<2.0.0,>=0.7.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from boto3>=1.20.41->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.1)\n", - "Requirement already satisfied: s3transfer<0.11.0,>=0.10.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from boto3>=1.20.41->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.10.1)\n", - "Requirement already satisfied: starlette<0.37.0,>=0.36.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from fastapi>=0.42.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.36.3)\n", - "Requirement already satisfied: attrs>=22.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (23.2.0)\n", - "Requirement already satisfied: jsonschema-specifications>=2023.03.6 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2023.12.1)\n", - "Requirement already satisfied: referencing>=0.28.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.33.0)\n", - "Requirement already satisfied: rpds-py>=0.7.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=3.1.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.18.0)\n", - "Requirement already satisfied: Click in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (8.1.7)\n", - "Requirement already satisfied: Flask>=1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.0.2)\n", - "Requirement already satisfied: sentinels in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from mongomock>=3.10.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.0)\n", - "Requirement already satisfied: annotated-types>=0.4.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pydantic>=2.0->emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (0.6.0)\n", - "Requirement already satisfied: python-dotenv>=0.21.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pydantic-settings>=2.0->emmet-core>=0.69.2->mp-api>=0.27.3->pymatgen==2023.9.10) (1.0.1)\n", - "Requirement already satisfied: paramiko>=2.7.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.4.0)\n", - "Requirement already satisfied: h11>=0.8 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from uvicorn>=0.18.3->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (0.14.0)\n", - "Requirement already satisfied: Werkzeug>=3.0.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.0.1)\n", - "Requirement already satisfied: Jinja2>=3.1.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (3.1.3)\n", - "Requirement already satisfied: itsdangerous>=2.1.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.1.2)\n", - "Requirement already satisfied: blinker>=1.6.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.7.0)\n", - "Requirement already satisfied: bcrypt>=3.2 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.1.2)\n", - "Requirement already satisfied: cryptography>=3.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (42.0.5)\n", - "Requirement already satisfied: pynacl>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.5.0)\n", - "Requirement already satisfied: anyio<5,>=3.4.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from starlette<0.37.0,>=0.36.3->fastapi>=0.42.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (4.3.0)\n", - "Requirement already satisfied: sniffio>=1.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from anyio<5,>=3.4.0->starlette<0.37.0,>=0.36.3->fastapi>=0.42.0->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.3.0)\n", - "Requirement already satisfied: cffi>=1.12 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from cryptography>=3.3->paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (1.16.0)\n", - "Requirement already satisfied: MarkupSafe>=2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from Jinja2>=3.1.2->Flask>=1.0->mongogrant>=0.3.1->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.1.5)\n", - "Requirement already satisfied: pycparser in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from cffi>=1.12->cryptography>=3.3->paramiko>=2.7.2->sshtunnel>=0.1.5->maggma>=0.57.1->mp-api>=0.27.3->pymatgen==2023.9.10) (2.21)\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" - ] - }, - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Installed pymatgen==2023.9.10\n", - "Requirement already satisfied: ase==3.22.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (3.22.1)\n", - "Requirement already satisfied: matplotlib>=3.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ase==3.22.1) (3.8.3)\n", - "Requirement already satisfied: numpy>=1.15.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ase==3.22.1) (1.26.4)\n", - "Requirement already satisfied: scipy>=1.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ase==3.22.1) (1.12.0)\n", - "Requirement already satisfied: contourpy>=1.0.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (1.2.0)\n", - "Requirement already satisfied: cycler>=0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (0.12.1)\n", - "Requirement already satisfied: fonttools>=4.22.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (4.49.0)\n", - "Requirement already satisfied: kiwisolver>=1.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (1.4.5)\n", - "Requirement already satisfied: packaging>=20.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (23.2)\n", - "Requirement already satisfied: pillow>=8 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (10.2.0)\n", - "Requirement already satisfied: pyparsing>=2.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (2.4.7)\n", - "Requirement already satisfied: python-dateutil>=2.7 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from matplotlib>=3.1.0->ase==3.22.1) (2.8.2)\n", - "Requirement already satisfied: six>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from python-dateutil>=2.7->matplotlib>=3.1.0->ase==3.22.1) (1.16.0)\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" - ] - }, - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Installed ase==3.22.1\n", - "Requirement already satisfied: pandas==1.5.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (1.5.3)\n", - "Requirement already satisfied: python-dateutil>=2.8.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas==1.5.3) (2.8.2)\n", - "Requirement already satisfied: pytz>=2020.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas==1.5.3) (2024.1)\n", - "Requirement already satisfied: numpy>=1.21.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pandas==1.5.3) (1.26.4)\n", - "Requirement already satisfied: six>=1.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from python-dateutil>=2.8.1->pandas==1.5.3) (1.16.0)\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" - ] - }, - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Installed pandas==1.5.3\n", - "Requirement already satisfied: ipywidgets in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (8.1.2)\n", - "Requirement already satisfied: comm>=0.1.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (0.2.1)\n", - "Requirement already satisfied: ipython>=6.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (8.22.1)\n", - "Requirement already satisfied: traitlets>=4.3.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (5.14.1)\n", - "Requirement already satisfied: widgetsnbextension~=4.0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (4.0.10)\n", - "Requirement already satisfied: jupyterlab-widgets~=3.0.10 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipywidgets) (3.0.10)\n", - "Requirement already satisfied: decorator in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (5.1.1)\n", - "Requirement already satisfied: jedi>=0.16 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (0.19.1)\n", - "Requirement already satisfied: matplotlib-inline in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (0.1.6)\n", - "Requirement already satisfied: prompt-toolkit<3.1.0,>=3.0.41 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (3.0.43)\n", - "Requirement already satisfied: pygments>=2.4.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (2.17.2)\n", - "Requirement already satisfied: stack-data in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (0.6.3)\n", - "Requirement already satisfied: pexpect>4.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from ipython>=6.1.0->ipywidgets) (4.9.0)\n", - "Requirement already satisfied: parso<0.9.0,>=0.8.3 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jedi>=0.16->ipython>=6.1.0->ipywidgets) (0.8.3)\n", - "Requirement already satisfied: ptyprocess>=0.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from pexpect>4.3->ipython>=6.1.0->ipywidgets) (0.7.0)\n", - "Requirement already satisfied: wcwidth in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from prompt-toolkit<3.1.0,>=3.0.41->ipython>=6.1.0->ipywidgets) (0.2.13)\n", - "Requirement already satisfied: executing>=1.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from stack-data->ipython>=6.1.0->ipywidgets) (2.0.1)\n", - "Requirement already satisfied: asttokens>=2.1.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from stack-data->ipython>=6.1.0->ipywidgets) (2.4.1)\n", - "Requirement already satisfied: pure-eval in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from stack-data->ipython>=6.1.0->ipywidgets) (0.2.2)\n", - "Requirement already satisfied: six>=1.12.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from asttokens>=2.1.0->stack-data->ipython>=6.1.0->ipywidgets) (1.16.0)\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" - ] - }, - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Installed ipywidgets\n", - "Requirement already satisfied: plotly==5.18 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (5.18.0)\n", - "Requirement already satisfied: tenacity>=6.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from plotly==5.18) (8.2.3)\n", - "Requirement already satisfied: packaging in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from plotly==5.18) (23.2)\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" - ] - }, - { - "name": "stdout", - "output_type": "stream", - "text": [ - "Installed plotly==5.18\n", - "Requirement already satisfied: nbformat>=4.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (5.9.2)\n", - "Requirement already satisfied: fastjsonschema in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (2.19.1)\n", - "Requirement already satisfied: jsonschema>=2.6 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (4.21.1)\n", - "Requirement already satisfied: jupyter-core in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (5.7.1)\n", - "Requirement already satisfied: traitlets>=5.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from nbformat>=4.2.0) (5.14.1)\n", - "Requirement already satisfied: attrs>=22.2.0 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (23.2.0)\n", - "Requirement already satisfied: jsonschema-specifications>=2023.03.6 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (2023.12.1)\n", - "Requirement already satisfied: referencing>=0.28.4 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (0.33.0)\n", - "Requirement already satisfied: rpds-py>=0.7.1 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jsonschema>=2.6->nbformat>=4.2.0) (0.18.0)\n", - "Requirement already satisfied: platformdirs>=2.5 in /Users/mat3ra/code/GREEN/api-examples/.venv/lib/python3.11/site-packages (from jupyter-core->nbformat>=4.2.0) (4.2.0)\n", - "Installed nbformat>=4.2.0\n", - "Packages installed successfully.\n" - ] - }, - { - "name": "stderr", - "output_type": "stream", - "text": [ - "\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m A new release of pip is available: \u001B[0m\u001B[31;49m23.3.2\u001B[0m\u001B[39;49m -> \u001B[0m\u001B[32;49m24.0\u001B[0m\n", - "\u001B[1m[\u001B[0m\u001B[34;49mnotice\u001B[0m\u001B[1;39;49m]\u001B[0m\u001B[39;49m To update, run: \u001B[0m\u001B[32;49mpip install --upgrade pip\u001B[0m\n" - ] - } - ], + "execution_count": null, + "metadata": {}, + "outputs": [], "source": [ "from jupyterlite.utils import install_packages\n", "\n", From 6003ee8a6985351701d92854608d6df562bf1519 Mon Sep 17 00:00:00 2001 From: Timur Bazhirov Date: Fri, 29 Mar 2024 19:05:24 -0700 Subject: [PATCH 07/10] update: publish to pypi --- .github/workflows/cicd.yml | 25 +++++++++++++++++++++++++ pyproject.toml | 16 ++++++++-------- 2 files changed, 33 insertions(+), 8 deletions(-) diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml index 1cc9e532..ec31c2f8 100644 --- a/.github/workflows/cicd.yml +++ b/.github/workflows/cicd.yml @@ -27,6 +27,31 @@ jobs: run: | python -m pip install pre-commit pre-commit run --all-files --show-diff-on-failure + + publish-py-package: + needs: [run-linter] + runs-on: ubuntu-latest + if: github.ref_name == 'dev' + + steps: + - name: Checkout this repository + uses: actions/checkout@v4 + with: + lfs: true + + - name: Checkout actions repository + uses: actions/checkout@v4 + with: + repository: Exabyte-io/actions + token: ${{ secrets.BOT_GITHUB_TOKEN }} + path: actions + + - name: Publish python release + uses: ./actions/py/publish + with: + python-version: 3.8.x + github-token: ${{ secrets.BOT_GITHUB_TOKEN }} + pypi-api-token: ${{ secrets.PYPI_API_TOKEN }} # TODO: Add back when when fixed. # build-and-deploy-docs: diff --git a/pyproject.toml b/pyproject.toml index 8df51515..362564b9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,23 +9,23 @@ description = "Mat3ra API Examples" readme = "README.md" requires-python = ">=3.8" -[project.optional-dependencies] -colab = [ +dependencies = [ "ase>=3.21.1", "exabyte-api-client>=2023.6.13.post0", "matplotlib>=3.4.1", "pandas>=1.5.3", "pymatgen>=2023.5.31", ] -localhost = [ - "ase>=3.21.1", - "exabyte-api-client>=2023.6.13.post0", - "matplotlib>=3.4.1", - "pandas>=1.1.4", - "pymatgen>=2023.5.31", + +[project.optional-dependencies] +# Install all above dependencies in colab +colab = ["mat3ra-api-examples"] +jupyterlab = [ "jupyterlab>=3.0.17", "nbconvert>=6.0.7", ] +# Install colab + jupyterlab on localhost +localhost = ["mat3ra-api-examples[jupyterlab]"] dev = [ "pre-commit>=3.3.3", "pip-tools>=6.13.0", From de93926c8395596acde6ed83517402950af28869 Mon Sep 17 00:00:00 2001 From: Timur Bazhirov Date: Fri, 29 Mar 2024 19:13:38 -0700 Subject: [PATCH 08/10] chore: whitespace --- .github/workflows/cicd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml index ec31c2f8..feb78351 100644 --- a/.github/workflows/cicd.yml +++ b/.github/workflows/cicd.yml @@ -27,7 +27,7 @@ jobs: run: | python -m pip install pre-commit pre-commit run --all-files --show-diff-on-failure - + publish-py-package: needs: [run-linter] runs-on: ubuntu-latest From f755e733ba6799f01fdeac44209c758047f81608 Mon Sep 17 00:00:00 2001 From: Timur Bazhirov Date: Fri, 29 Mar 2024 19:27:44 -0700 Subject: [PATCH 09/10] chore: dynamic version --- .../import_material_from_jarvis_db_entry.ipynb | 2 +- .../run_job_using_material_from_jarvis_db.ipynb | 2 +- pyproject.toml | 14 ++++++++------ 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/other/jarvis/import_material_from_jarvis_db_entry.ipynb b/other/jarvis/import_material_from_jarvis_db_entry.ipynb index 4f7cfea0..c8474308 100644 --- a/other/jarvis/import_material_from_jarvis_db_entry.ipynb +++ b/other/jarvis/import_material_from_jarvis_db_entry.ipynb @@ -134,4 +134,4 @@ }, "nbformat": 4, "nbformat_minor": 5 -} +} \ No newline at end of file diff --git a/other/jarvis/run_job_using_material_from_jarvis_db.ipynb b/other/jarvis/run_job_using_material_from_jarvis_db.ipynb index bd1153a3..12db40f2 100644 --- a/other/jarvis/run_job_using_material_from_jarvis_db.ipynb +++ b/other/jarvis/run_job_using_material_from_jarvis_db.ipynb @@ -571,4 +571,4 @@ }, "nbformat": 4, "nbformat_minor": 5 -} +} \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 362564b9..d64f835a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,14 +1,9 @@ -[build-system] -requires = ["setuptools>=64", "setuptools_scm[toml]>=6.2", "wheel"] -build-backend = "setuptools.build_meta" - [project] name = "mat3ra-api-examples" -version = "0.1.0" +dynamic = ["version"] description = "Mat3ra API Examples" readme = "README.md" requires-python = ">=3.8" - dependencies = [ "ase>=3.21.1", "exabyte-api-client>=2023.6.13.post0", @@ -47,6 +42,13 @@ repository = "https://github.com/Exabyte-io/api-examples" [project.scripts] notebook-path = "utils.notebook:print_notebook_path" +[build-system] +requires = ["setuptools>=64", "setuptools_scm[toml]>=6.2", "wheel"] +build-backend = "setuptools.build_meta" + +[tool.setuptools_scm] +git_describe_command = "git describe --tags --long" + [tool.setuptools.packages.find] include = ["utils"] From c45a0834448b7b01411babe039a7af588c4b1953 Mon Sep 17 00:00:00 2001 From: Timur Bazhirov Date: Fri, 29 Mar 2024 19:49:09 -0700 Subject: [PATCH 10/10] chore: whitespace --- other/jarvis/import_material_from_jarvis_db_entry.ipynb | 2 +- other/jarvis/run_job_using_material_from_jarvis_db.ipynb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/other/jarvis/import_material_from_jarvis_db_entry.ipynb b/other/jarvis/import_material_from_jarvis_db_entry.ipynb index c8474308..4f7cfea0 100644 --- a/other/jarvis/import_material_from_jarvis_db_entry.ipynb +++ b/other/jarvis/import_material_from_jarvis_db_entry.ipynb @@ -134,4 +134,4 @@ }, "nbformat": 4, "nbformat_minor": 5 -} \ No newline at end of file +} diff --git a/other/jarvis/run_job_using_material_from_jarvis_db.ipynb b/other/jarvis/run_job_using_material_from_jarvis_db.ipynb index 12db40f2..bd1153a3 100644 --- a/other/jarvis/run_job_using_material_from_jarvis_db.ipynb +++ b/other/jarvis/run_job_using_material_from_jarvis_db.ipynb @@ -571,4 +571,4 @@ }, "nbformat": 4, "nbformat_minor": 5 -} \ No newline at end of file +}