{ "cells": [ { "cell_type": "markdown", "id": "e7121bac", "metadata": {}, "source": [ "## format of PartMC raw output" ] }, { "cell_type": "markdown", "id": "d06d2ef7", "metadata": {}, "source": [ "[Here](../data/urban_plume_0001_00000002.nc) is a sample of PartMC raw output" ] }, { "cell_type": "code", "execution_count": 1, "id": "c3f42566", "metadata": {}, "outputs": [ { "data": { "text/html": [ "
\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "
<xarray.Dataset>\n",
       "Dimensions:                     (gas_species: 77, aero_species: 20,\n",
       "                                 aero_source: 8, aero_weight_group: 2,\n",
       "                                 aero_weight_class: 8, aero_particle: 1246,\n",
       "                                 aero_removed: 4636)\n",
       "Coordinates:\n",
       "  * gas_species                 (gas_species) int32 1 2 3 4 5 ... 73 74 75 76 77\n",
       "  * aero_species                (aero_species) int32 1 2 3 4 5 ... 17 18 19 20\n",
       "  * aero_source                 (aero_source) int32 1 2 3 4 5 6 7 8\n",
       "  * aero_weight_group           (aero_weight_group) int32 1 2\n",
       "  * aero_weight_class           (aero_weight_class) int32 1 2 3 4 5 6 7 8\n",
       "  * aero_particle               (aero_particle) int32 1 2 3 4 ... 1244 1245 1246\n",
       "  * aero_removed                (aero_removed) int32 1 2 3 4 ... 4634 4635 4636\n",
       "Data variables: (12/48)\n",
       "    time                        float64 3.6e+03\n",
       "    timestep                    float64 60.0\n",
       "    timestep_index              int32 2\n",
       "    repeat                      int32 1\n",
       "    temperature                 float64 292.5\n",
       "    relative_humidity           float64 0.8126\n",
       "    ...                          ...\n",
       "    aero_refract_core_real      (aero_particle) float64 0.0 0.0 0.0 ... 0.0 0.0\n",
       "    aero_refract_core_imag      (aero_particle) float64 0.0 0.0 0.0 ... 0.0 0.0\n",
       "    aero_core_vol               (aero_particle) float64 0.0 0.0 0.0 ... 0.0 0.0\n",
       "    aero_removed_id             (aero_removed) int32 134 602 715 ... 5534 5783\n",
       "    aero_removed_action         (aero_removed) int32 1 1 1 4 3 3 ... 1 1 1 1 1 4\n",
       "    aero_removed_other_id       (aero_removed) int32 32767 32767 ... 32767 0\n",
       "Attributes:\n",
       "    title:        PartMC version 2.5.0 output file\n",
       "    source:       PartMC version 2.5.0\n",
       "    UUID:         A96876F0-F62E-45FB-AC47-2FB221548641\n",
       "    history:      2021-09-22T15:54:26.773-05:00 created by PartMC version 2.5.0\n",
       "    Conventions:  CF-1.4
" ], "text/plain": [ "\n", "Dimensions: (gas_species: 77, aero_species: 20,\n", " aero_source: 8, aero_weight_group: 2,\n", " aero_weight_class: 8, aero_particle: 1246,\n", " aero_removed: 4636)\n", "Coordinates:\n", " * gas_species (gas_species) int32 1 2 3 4 5 ... 73 74 75 76 77\n", " * aero_species (aero_species) int32 1 2 3 4 5 ... 17 18 19 20\n", " * aero_source (aero_source) int32 1 2 3 4 5 6 7 8\n", " * aero_weight_group (aero_weight_group) int32 1 2\n", " * aero_weight_class (aero_weight_class) int32 1 2 3 4 5 6 7 8\n", " * aero_particle (aero_particle) int32 1 2 3 4 ... 1244 1245 1246\n", " * aero_removed (aero_removed) int32 1 2 3 4 ... 4634 4635 4636\n", "Data variables: (12/48)\n", " time float64 ...\n", " timestep float64 ...\n", " timestep_index int32 ...\n", " repeat int32 ...\n", " temperature float64 ...\n", " relative_humidity float64 ...\n", " ... ...\n", " aero_refract_core_real (aero_particle) float64 ...\n", " aero_refract_core_imag (aero_particle) float64 ...\n", " aero_core_vol (aero_particle) float64 ...\n", " aero_removed_id (aero_removed) int32 ...\n", " aero_removed_action (aero_removed) int32 ...\n", " aero_removed_other_id (aero_removed) int32 ...\n", "Attributes:\n", " title: PartMC version 2.5.0 output file\n", " source: PartMC version 2.5.0\n", " UUID: A96876F0-F62E-45FB-AC47-2FB221548641\n", " history: 2021-09-22T15:54:26.773-05:00 created by PartMC version 2.5.0\n", " Conventions: CF-1.4" ] }, "execution_count": 1, "metadata": {}, "output_type": "execute_result" } ], "source": [ "import xarray as xr\n", "p = \"../data/urban_plume_0001_00000002.nc\"\n", "ds = xr.open_dataset(p)\n", "ds" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.8.13" } }, "nbformat": 4, "nbformat_minor": 5 }