diff --git a/README.md b/README.md index 2ec67d1..ceeb6fa 100644 --- a/README.md +++ b/README.md @@ -1,34 +1,6 @@ -# `c_therm_tci.py` +# C-Therm TCi instrument usage and data process -Process data exported from the C-Therm TCi thermal conductivity analyzer. - -## Usage - -First install Python 3.11 and `pipx`. See the [quick setup guide](#windows-quick-setup) for details on Windows machine setup. The `c_therm_tci.py` script processes the TCi C-Therm instrument's XML data exports into CSV files. For instance, to process the [example data](#example-data) locally, download [`c_therm_tci.py`](src/c_therm_tci.py), [`data.xml`](example/data.xml) and [`data.xlsx`](example/data.xlsx) to your Desktop. Then, right-click on your Desktop, click "Open in Terminal", and run - -```Shell -py -3.11 -m pipx run c_therm_tci.py -``` - -which processes `data.xml` into `data.csv`. Now, open `data.xlsx`, click to enable data connections, then click `Refresh all` in the `Data` ribbon *twice* to refresh the Power Queries and PivotTable. This example data and the Excel workbook illustrates how to process arbitrary data exports from the C-Therm TCi instrument. - -## Example data - -The example data folder in this repo has `data.xml`, a simplified representation of the shape of data exported from the C-Therm TCi instrument and `data.csv` represents the result of processing with `c_therm_tci.py`. - -The `data.xlsx` workbook ingests and post-processes `data.csv`. The `setup` sheet programmatically finds `data.csv` for Power Query, `raw_data` shows CSV data, `grouped_averages` groups and averages results by test run, and `results` further digests the data. `grouped_averages` also allows overriding the "validity" of a test result and to provide a comment about each test. - -## Windows quick setup - -This is the quickest way to get set up on Windows for running this Python script, and for Python scripts in general. Install [App Installer (`winget`)](https://apps.microsoft.com/detail/9nblggh4nns1). If this fails you may need to go to the Microsoft Store app, click `Library`, then `Get Updates`, then `Update all`, then try installing `winget` again. Also install [Windows Terminal](https://apps.microsoft.com/detail/9mz1snwt0n5d), then open Windows Terminal from the Start menu. Run - -```Shell -winget install --id 'Python.Python.3.11' --override '/quiet PrependPath=0' -py -3.11 -m pip install pipx -py -3.11 -m pipx ensurepath -``` - -which will install Python 3.11 and `pipx`, and configure `pipx`. +Process data exported from the C-Therm TCi thermal conductivity analyzer. See the how to [process data](https://blakenaccarato.github.io/c-therm-tci/) exported from the instrument or [the tutorial](https://blakenaccarato.github.io/c-therm-tci/tutorial.html) to learn how to use the instrument. ## Project information diff --git a/docs/conf.py b/docs/conf.py index a97f74f..10ee643 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -170,7 +170,7 @@ def dpath(path: Path, rel: Path = DOCS) -> str: # ! Autodoc2 nitpicky = True autodoc2_packages = [ - f"../src/{PACKAGE}", + f"../src/{PACKAGE}.py", f"{PACKAGE}_docs", f"../tests/{PACKAGE}_tests", f"../scripts/{PACKAGE}_tools", @@ -185,12 +185,17 @@ def dpath(path: Path, rel: Path = DOCS) -> str: autodoc2_docstring_parser_regexes = [(".*", f"{PACKAGE}_docs.docstrings")] # ! Intersphinx intersphinx_mapping = ISPX_MAPPING -nitpick_ignore = [] +nitpick_ignore = [ + # ? Not found + ("py:class", "parsel.Selector") +] nitpick_ignore_regex = [ # ? Missing inventory ("py:class", r"docutils\..+"), ("py:class", r"numpydoc\.docscrape\..+"), ("py:class", r"_pytest\..+"), + # ? Missing target + ("py:class", r"parsel\.Selector.+"), # ? TypeAlias: https://github.com/sphinx-doc/sphinx/issues/10785 ("py:class", rf"{PACKAGE}.*\.types\..+"), ] diff --git a/docs/index.md b/docs/index.md index dad321d..c7bcb37 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,5 +1,3 @@ -# [`c_therm_tci.py`](https://github.com/blakeNaccarato/c-therm-tci) - :::{toctree} :hidden: tutorial @@ -8,3 +6,41 @@ changelog apidocs/index references ::: + +# C-Therm TCi instrument usage and data process + +Process data exported from the C-Therm TCi thermal conductivity analyzer. See below for processing data exported from the instrument, or to learn how to use the instrument. + +## Usage + +First install Python 3.11 and `pipx`. See the [quick setup guide](#windows-quick-setup) for details on Windows machine setup. The `c_therm_tci.py` script processes the TCi C-Therm instrument's XML data exports into CSV files. For instance, to process the [example data](#example-data) locally, download [`c_therm_tci.py`](../src/c_therm_tci.py), [`data.xml`](../example/data.xml) and [`data.xlsx`](../example/data.xlsx) to your Desktop. Then, right-click on your Desktop, click "Open in Terminal", and run + +```Shell +py -3.11 -m pipx run c_therm_tci.py +``` + +which processes `data.xml` into `data.csv`. Now, open `data.xlsx`, click to enable data connections, then click `Refresh all` in the `Data` ribbon *twice* to refresh the Power Queries and PivotTable. This example data and the Excel workbook illustrates how to process arbitrary data exports from the C-Therm TCi instrument. + +## Example data + +The example data folder in this repo has `data.xml`, a simplified representation of the shape of data exported from the C-Therm TCi instrument and `data.csv` represents the result of processing with `c_therm_tci.py`. + +The `data.xlsx` workbook ingests and post-processes `data.csv`. The `setup` sheet programmatically finds `data.csv` for Power Query, `raw_data` shows CSV data, `grouped_averages` groups and averages results by test run, and `results` further digests the data. `grouped_averages` also allows overriding the "validity" of a test result and to provide a comment about each test. + +## Windows quick setup + +This is the quickest way to get set up on Windows for running this Python script, and for Python scripts in general. Install [App Installer (`winget`)](https://apps.microsoft.com/detail/9nblggh4nns1). If this fails you may need to go to the Microsoft Store app, click `Library`, then `Get Updates`, then `Update all`, then try installing `winget` again. Also install [Windows Terminal](https://apps.microsoft.com/detail/9mz1snwt0n5d), then open Windows Terminal from the Start menu. Run + +```Shell +winget install --id 'Python.Python.3.11' --override '/quiet PrependPath=0' +py -3.11 -m pip install pipx +py -3.11 -m pipx ensurepath +``` + +which will install Python 3.11 and `pipx`, and configure `pipx`. + +## Project information + +- [Changes]() +- [Docs]() +- [Contributing]() diff --git a/docs/tutorial.md b/docs/tutorial.md index 5e0f1e2..123dc91 100644 --- a/docs/tutorial.md +++ b/docs/tutorial.md @@ -1,95 +1,211 @@ # Tutorial -![](_static/00.png) +```{figure} _static/01.png +:alt: -![](_static/01.png) +``` -![](_static/02.png) +```{figure} _static/02.png +:alt: -![](_static/03.png) +``` -![](_static/04.png) +```{figure} _static/03.png +:alt: -![](_static/05.png) +``` -![](_static/06.png) +```{figure} _static/04.png +:alt: -![](_static/07.png) +``` -![](_static/08.png) +```{figure} _static/05.png +:alt: -![](_static/09.png) +``` -![](_static/10.png) +```{figure} _static/06.png +:alt: -![](_static/11.png) +``` -![](_static/12.png) +```{figure} _static/07.png +:alt: -![](_static/13.png) +``` -![](_static/14.png) +```{figure} _static/08.png +:alt: -![](_static/15.png) +``` -![](_static/16.png) +```{figure} _static/09.png +:alt: -![](_static/17.png) +``` -![](_static/18.png) +```{figure} _static/10.png +:alt: -![](_static/19.png) +``` -![](_static/20.png) +```{figure} _static/11.png +:alt: -![](_static/21.png) +``` -![](_static/22.png) +```{figure} _static/12.png +:alt: -![](_static/23.png) +``` -![](_static/24.png) +```{figure} _static/13.png +:alt: -![](_static/25.png) +``` -![](_static/26.png) +```{figure} _static/14.png +:alt: -![](_static/27.png) +``` -![](_static/28.png) +```{figure} _static/15.png +:alt: -![](_static/29.png) +``` -![](_static/30.png) +```{figure} _static/16.png +:alt: -![](_static/31.png) +``` -![](_static/32.png) +```{figure} _static/17.png +:alt: -![](_static/33.png) +``` -![](_static/34.png) +```{figure} _static/18.png +:alt: -![](_static/35.png) +``` -![](_static/36.png) +```{figure} _static/19.png +:alt: -![](_static/37.png) +``` -![](_static/38.png) +```{figure} _static/20.png +:alt: -![](_static/39.png) +``` -![](_static/40.png) +```{figure} _static/21.png +:alt: -![](_static/41.png) +``` -![](_static/42.png) +```{figure} _static/22.png +:alt: -![](_static/43.png) +``` -![](_static/44.png) +```{figure} _static/23.png +:alt: -![](_static/45.png) +``` -![](_static/46.png) +```{figure} _static/24.png +:alt: + +``` + +```{figure} _static/25.png +:alt: + +``` + +```{figure} _static/26.png +:alt: + +``` + +```{figure} _static/27.png +:alt: + +``` + +```{figure} _static/28.png +:alt: + +``` + +```{figure} _static/29.png +:alt: + +``` + +```{figure} _static/30.png +:alt: + +``` + +```{figure} _static/31.png +:alt: + +``` + +```{figure} _static/32.png +:alt: + +``` + +```{figure} _static/33.png +:alt: + +``` + +```{figure} _static/34.png +:alt: + +``` + +```{figure} _static/35.png +:alt: + +``` + +```{figure} _static/36.png +:alt: + +``` + +```{figure} _static/37.png +:alt: + +``` + +```{figure} _static/38.png +:alt: + +``` + +```{figure} _static/39.png +:alt: + +``` + +```{figure} _static/40.png +:alt: + +``` + +```{figure} _static/41.png +:alt: + +``` + +```{figure} _static/42.png +:alt: + +``` diff --git a/scripts/c_therm_tci_tools/sync.py b/scripts/c_therm_tci_tools/sync.py index 435bb7b..59fc212 100644 --- a/scripts/c_therm_tci_tools/sync.py +++ b/scripts/c_therm_tci_tools/sync.py @@ -9,8 +9,6 @@ from subprocess import run from sys import version_info -from ruamel.yaml import YAML - from c_therm_tci_tools.types import Platform, PythonVersion # ! For local dev config tooling @@ -32,10 +30,6 @@ """Dependencies appended to locks without compiling their dependencies.""" OVERRIDE = REQS / "override.txt" """Overrides to satisfy otherwise incompatible combinations.""" -SYS_PYTHON_VERSION = YAML().load(COPIER_ANSWERS.read_text(encoding="utf-8"))[ - "python_version" -] -"""Python version.""" # ! Platforms and Python versions SYS_PLATFORM: Platform = platform(terse=True).casefold().split("-")[0] # pyright: ignore[reportAssignmentType] 1.1.356 diff --git a/scripts/pyproject.toml b/scripts/pyproject.toml index 0aa94b6..3620eeb 100644 --- a/scripts/pyproject.toml +++ b/scripts/pyproject.toml @@ -11,7 +11,6 @@ dependencies = [ "copier==9.2.0", "cyclopts==2.6.1", "pipx==1.5.0", - "ruamel-yaml==0.18.6", ] [project.scripts] "c_therm_tci_tools" = "c_therm_tci_tools.__main__:main" @@ -30,5 +29,3 @@ ignore_unused = [ "copier", # For template sync "pipx", # For `pipx run` of scripts with dependencies isolated by PEP 723 ] -[tool.fawltydeps.custom_mapping] -ruamel-yaml = ["ruamel"]