Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update documentation with details about EVO/Fluent differences #70

Merged
merged 6 commits into from
Apr 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ myst-nb
numpydoc
nbsphinx
sphinx-book-theme
sphinxcontrib.mermaid
1 change: 1 addition & 0 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
"numpydoc",
"myst_nb",
"sphinx_book_theme",
"sphinxcontrib.mermaid",
]
nb_execution_mode = "off"

Expand Down
29 changes: 21 additions & 8 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
@@ -1,23 +1,37 @@
Welcome to the ``robotools`` documentation!
===========================================

.. image:: https://img.shields.io/pypi/v/robotools
:target: https://pypi.org/project/robotools

.. image:: https://img.shields.io/badge/code%20on-Github-lightgrey
:target: https://github.com/JuBiotech/robotools
:target: https://github.com/JuBiotech/robotools

.. image:: https://zenodo.org/badge/358629210.svg
:target: https://zenodo.org/badge/latestdoi/358629210


``robotools`` is a Python package for planning *in silico* liquid handling operations.
It can create Tecan Freedom EVO worklist files on the fly, making it possible to program complicated liquid handling operations

It can create Tecan Freedom EVO or Tecan Fluent worklist files on the fly, making it possible to program complicated liquid handling operations
from Python scripts or Jupyter notebooks.

You can download the latest version from `GitHub <https://github.com/JuBiotech/robotools>`_ or install it via ``pip install robotools``.
Installation
============

.. code-block:: bash

pip install robotools

You can also download the latest version from `GitHub <https://github.com/JuBiotech/robotools>`_.

Tutorials
=========

In the following chapters, we introduce the data structures, worklist-creation and extra features.

.. toctree::
:maxdepth: 2
:caption: Examples
:maxdepth: 1

notebooks/01_Labware_Basics
notebooks/02_Worklist_Basics
Expand All @@ -28,12 +42,11 @@ In the following chapters, we introduce the data structures, worklist-creation a
notebooks/07_TipMasks



You can find autogenerated API documentation below:
API Reference
=============

.. toctree::
:maxdepth: 2
:caption: API Reference

robotools_liquidhandling
robotools_evotools
Expand Down
50 changes: 33 additions & 17 deletions docs/source/notebooks/01_Labware_Basics.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@
"metadata": {},
"source": [
"# `Labware` Basics\n",
"In `robotools` there are two important types of objects: `Labware` and `Worklist`.\n",
"In `robotools` there are two important types of objects: `Labware` and worklists.\n",
"\n",
"A `Labware` represents an array of wells, such as a microtiter plate (MTP), one or more troughs or even an arrangement of eppis or falcon tubes.\n",
"\n",
"The `Worklist` helps you to perform liquid handling operations on `Labware` objects while automatically creating an EVOware Worklist file (`*.gwl`) with the corresponding pipetting instructions.\n",
"These files contain things like source/destination, volume and can be executed by a Tecan EVOware script.\n",
"The worklists help you to perform liquid handling operations on `Labware` objects while automatically creating a Gemini worklist file (`*.gwl`) with the corresponding pipetting instructions.\n",
"These files contain things like source/destination, volume and can be executed by a Tecan EVO or Fluent liquid handlers.\n",
"\n",
"But before we'll get creating worklists, this example introduces how `robotools` generally deals with liquid handling."
]
},
Expand Down Expand Up @@ -37,8 +39,9 @@
"Each `Labware` object describes a $R\\times C$ grid (array) of wells.\n",
"It has a `name` and `min_volume`/`max_volume` to prevent you from pipetting impossible volumes.\n",
"\n",
"The following cell creates a `Labware` with the name \"24-well plate\".\n",
"When creating worklists, this name should match the labware defined on the EVOware worktable."
"The following cell creates a `Labware` with the name `\"24-well plate\"`.\n",
"\n",
"When creating worklists, this name should match the labware defined on the liquid handler worktable."
]
},
{
Expand Down Expand Up @@ -67,7 +70,8 @@
],
"source": [
"plate = robotools.Labware(\n",
" \"24-well plate\", rows=4, columns=6, \n",
" \"24-well plate\",\n",
" rows=4, columns=6, \n",
" min_volume=100, max_volume=1_000,\n",
" initial_volumes=300\n",
")\n",
Expand Down Expand Up @@ -149,6 +153,7 @@
"metadata": {},
"source": [
"If you are familiar with Python already, you probably know how [NumPy slicing](https://www.w3schools.com/python/numpy_array_slicing.asp) works.\n",
"\n",
"Because `.wells` and `.volumes` are NumPy `ndarray`s, you can use NumPy slicing to select particular ranges:"
]
},
Expand Down Expand Up @@ -186,7 +191,8 @@
"metadata": {},
"source": [
"`Labware`s have methods such as `.add()`, `.remove()` for performing virtual liquid handling operations.\n",
"You won't typically work with `.add()` or `.remove()` directly, because most things you do with a `Worklist` will call these methods under the hood.\n",
"\n",
"You won't typically work with `.add()` or `.remove()` directly, because most things you do with a worklist will call these methods under the hood.\n",
"\n",
"One job of the `.add()` and `.remove()` methods is to raise `VolumeOverflowError` or `VolumeUnderflowError` when the minimum/maximum working volumes are violated:"
]
Expand All @@ -213,11 +219,8 @@
],
"source": [
"try:\n",
" \n",
" plate.add(['A01', 'B01', 'C01'], [200, 200, 2000])\n",
" \n",
"# The try/except is just to make the example look nice.\n",
"except Exception as ex:\n",
"except robotools.VolumeViolationException as ex:\n",
" print(ex)"
]
},
Expand Down Expand Up @@ -271,9 +274,10 @@
"metadata": {},
"source": [
"### Troughs\n",
"Troughs are a little weird, because for the EVOware, they have multiple rows, even though it's actually just one big well.\n",
"\n",
"Troughs are a little weird, because for the EVOware, they have multiple rows, even though it's actually just one big well.\n",
"Nevertheless, a `Trough` is just a special type of `Labware` that has `virtual_rows`.\n",
"For the Tecan Fluent, the `virtual_rows` setting is irrelevant.\n",
"\n",
"The following example emulates an arrangement of 4 troughs next to each other.\n",
"They have `virtual_rows=8`, so there's enough space for 8 tips (`A01` through `H01`), but in reality it's just one well per column:"
Expand Down Expand Up @@ -349,7 +353,7 @@
"source": [
"vwells = robotools.get_trough_wells(\n",
" n=11,\n",
" trough_wells=quadruple_trough.wells[:, 0] # select the wells from the first trough\n",
" trough_wells=quadruple_trough.wells[:, 0] # select the wells from the first trough\n",
")\n",
"\n",
"quadruple_trough.remove(vwells, 100)\n",
Expand All @@ -365,10 +369,22 @@
},
{
"cell_type": "code",
"execution_count": null,
"execution_count": 10,
"metadata": {},
"outputs": [],
"source": []
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Last updated: 2024-04-23T13:11:50.287028+02:00\n",
"\n"
]
}
],
"source": [
"%load_ext watermark\n",
"%watermark -idu"
]
}
],
"metadata": {
Expand All @@ -387,7 +403,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.16"
"version": "3.10.8"
}
},
"nbformat": 4,
Expand Down
Loading
Loading