Skip to content
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
288 changes: 144 additions & 144 deletions DataSimulations/Introduction_to_Decks.ipynb
Original file line number Diff line number Diff line change
@@ -1,144 +1,144 @@
{
"cells": [
{
"cell_type": "markdown",
"id": "baf9fb61-2fc5-446c-9c4a-18801c7d7afa",
"metadata": {},
"source": [
"**Welcome to PyLabRobot!**\n",
"\n",
"PyLabRobot is a universal Python interface to liquid-handling robots. Liquid-handling robots aspirate and dispense precise volumes\n",
"of liquid in a Cartesian coordinate system, essentially the same as hand pipetting.\n",
"\n",
"PLR defines a universal interface class called LiquidHandler that provides generic methods for controlling robots\n",
"such as aspirate and dispense. This class can be instantiated with one of several backends (or drivers)\n",
"that convert generic commands to machine-specific commands. This makes it easy to write code that will\n",
"be translatable across many different machines.\n",
"\n",
"First we will import `LiquidHandler`, a backend called `ChatterBoxBackend` that prints the text\n",
"output of our commands, a class `Visualizer` that provides a visualization of the robot deck as we\n",
"run commands, and a class `STARLetDeck` that will represent the deck of a Hamilton Microlab STARLet, one of\n",
"the most widely used liquid handling robots."
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "f8bcf094-3c3a-41c4-b0e8-5d2caeee9ca9",
"metadata": {},
"outputs": [],
"source": [
"from pylabrobot.liquid_handling import LiquidHandler\n",
"from pylabrobot.liquid_handling.backends import ChatterBoxBackend\n",
"from pylabrobot.visualizer.visualizer import Visualizer\n",
"from pylabrobot.resources.hamilton import STARLetDeck\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "8b372972-d6dc-454b-95eb-d9941405621b",
"metadata": {},
"outputs": [],
"source": [
"lh = LiquidHandler(backend=ChatterBoxBackend(), deck=STARLetDeck())\n",
"await lh.setup()"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "0324171c-101d-4b3d-9103-a0137c620174",
"metadata": {},
"outputs": [],
"source": [
"vis = Visualizer(resource=lh)\n",
"await vis.setup()"
]
},
{
"cell_type": "markdown",
"id": "59b03cfb-8e42-441e-9887-e7a87453d7f7",
"metadata": {},
"source": [
"Now we will import a tip carrier, a plate carrier, a plate, and a tip rack."
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "7bb36402-2303-4d2e-bd3e-4e10a29e891c",
"metadata": {},
"outputs": [],
"source": [
"from pylabrobot.resources import (\n",
" TIP_CAR_480_A00,\n",
" PLT_CAR_L5AC_A00,\n",
" Cos_96_DW_1mL,\n",
" HTF_L\n",
")\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "25faa001-8f09-43af-ac2a-5b6b6b21d47a",
"metadata": {},
"outputs": [],
"source": [
"tip_car = TIP_CAR_480_A00(name='tip carrier')\n",
"tip_car[0] = tip_rack1 = HTF_L(name='tips_01', with_tips=False)\n",
"tip_car[1] = tip_rack2 = HTF_L(name='tips_02', with_tips=False)\n",
"tip_car[2] = tip_rack3 = HTF_L(name='tips_03', with_tips=False)\n",
"tip_car[3] = tip_rack4 = HTF_L(name='tips_04', with_tips=False)\n",
"tip_car[4] = tip_rack5 = HTF_L(name='tips_05', with_tips=False)\n",
"lh.deck.assign_child_resource(tip_car, rails=15)\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "5e7c1218-70e9-4905-b15a-16af3259c79f",
"metadata": {},
"outputs": [],
"source": [
"plt_car = PLT_CAR_L5AC_A00(name='plate carrier')\n",
"plt_car[0] = plate_1 = Cos_96_DW_1mL(name='plate_01')\n",
"plt_car[1] = plate_2 = Cos_96_DW_1mL(name='plate_02')\n",
"plt_car[2] = plate_3 = Cos_96_DW_1mL(name='plate_03')\n",
"lh.deck.assign_child_resource(plt_car, rails=8)\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "08fb2161-4fc7-4312-9864-e85a46f02bcc",
"metadata": {},
"outputs": [],
"source": [
"await vis.stop()\n"
]
}
],
"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.11.0"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
{
"cells": [
{
"cell_type": "markdown",
"id": "baf9fb61-2fc5-446c-9c4a-18801c7d7afa",
"metadata": {},
"source": [
"**Welcome to PyLabRobot!**\n",
"\n",
"PyLabRobot is a universal Python interface to liquid-handling robots. Liquid-handling robots aspirate and dispense precise volumes\n",
"of liquid in a Cartesian coordinate system, essentially the same as hand pipetting.\n",
"\n",
"PLR defines a universal interface class called LiquidHandler that provides generic methods for controlling robots\n",
"such as aspirate and dispense. This class can be instantiated with one of several backends (or drivers)\n",
"that convert generic commands to machine-specific commands. This makes it easy to write code that will\n",
"be translatable across many different machines.\n",
"\n",
"First we will import `LiquidHandler`, a backend called `ChatterBoxBackend` that prints the text\n",
"output of our commands, a class `Visualizer` that provides a visualization of the robot deck as we\n",
"run commands, and a class `STARLetDeck` that will represent the deck of a Hamilton Microlab STARLet, one of\n",
"the most widely used liquid handling robots."
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "f8bcf094-3c3a-41c4-b0e8-5d2caeee9ca9",
"metadata": {},
"outputs": [],
"source": [
"from pylabrobot.liquid_handling import LiquidHandler\n",
"from pylabrobot.liquid_handling.backends import ChatterBoxBackend\n",
"from pylabrobot.visualizer.visualizer import Visualizer\n",
"from pylabrobot.resources.hamilton import STARLetDeck\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "8b372972-d6dc-454b-95eb-d9941405621b",
"metadata": {},
"outputs": [],
"source": [
"lh = LiquidHandler(backend=ChatterBoxBackend(), deck=STARLetDeck())\n",
"await lh.setup()"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "0324171c-101d-4b3d-9103-a0137c620174",
"metadata": {},
"outputs": [],
"source": [
"vis = Visualizer(resource=lh)\n",
"await vis.setup()"
]
},
{
"cell_type": "markdown",
"id": "59b03cfb-8e42-441e-9887-e7a87453d7f7",
"metadata": {},
"source": [
"Now we will import a tip carrier, a plate carrier, a plate, and a tip rack."
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "7bb36402-2303-4d2e-bd3e-4e10a29e891c",
"metadata": {},
"outputs": [],
"source": [
"from pylabrobot.resources import (\n",
" TIP_CAR_480_A00,\n",
" PLT_CAR_L5AC_A00,\n",
" Cos_96_DW_1mL,\n",
" HTF_L\n",
")\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "25faa001-8f09-43af-ac2a-5b6b6b21d47a",
"metadata": {},
"outputs": [],
"source": [
"tip_car = TIP_CAR_480_A00(name='tip carrier')\n",
"tip_car[0] = tip_rack1 = HTF_L(name='tips_01', with_tips=False)\n",
"tip_car[1] = tip_rack2 = HTF_L(name='tips_02', with_tips=False)\n",
"tip_car[2] = tip_rack3 = HTF_L(name='tips_03', with_tips=False)\n",
"tip_car[3] = tip_rack4 = HTF_L(name='tips_04', with_tips=False)\n",
"tip_car[4] = tip_rack5 = HTF_L(name='tips_05', with_tips=False)\n",
"lh.deck.assign_child_resource(tip_car, rails=15)\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "5e7c1218-70e9-4905-b15a-16af3259c79f",
"metadata": {},
"outputs": [],
"source": [
"plt_car = PLT_CAR_L5AC_A00(name='plate carrier')\n",
"plt_car[0] = plate_1 = Cos_96_DW_1mL(name='plate_01')\n",
"plt_car[1] = plate_2 = Cos_96_DW_1mL(name='plate_02')\n",
"plt_car[2] = plate_3 = Cos_96_DW_1mL(name='plate_03')\n",
"lh.deck.assign_child_resource(plt_car, rails=8)\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "08fb2161-4fc7-4312-9864-e85a46f02bcc",
"metadata": {},
"outputs": [],
"source": [
"await vis.stop()\n"
]
}
],
"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.11.0"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
Loading