# Getting started and encountering "ModuleNotFoundError"

**URL:** <https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85>\
**Category:** General\
**Created:** [December 2, 2024, 6:10am UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85 "2024-12-02T06:10:00Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 2, 2024, 6:10am UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/1 "2024-12-02T06:10:00Z")

</div>

Hi all,

I’m sorry to ask something so basic, but I’ve installed pylabrobot, but get an error when attempting to import anything.

When I call

> from pylabrobot.centrifuge import Centrifuge

I get the error:

> ModuleNotFoundError: No module named ‘pylabrobot.centrifuge’

Same with the liquid handler class. Why am I getting this error? I’ve looked all over for some step I’m missing, but as far as I can tell, I’ve installed the software normally, but it gives an error when I try to run the first line of example code for any operation. Any advice?

Thanks!

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 2, 2024, 7:35pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/2 "2024-12-02T19:35:09Z")

</div>

welcome to the forum!

first, did you install from pypi or from git? pypi is outdated and i recommend installing from source. [Installation — PyLabRobot documentation](https://docs.pylabrobot.org/user_guide/installation.html)

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 2, 2024, 11:14pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/3 "2024-12-02T23:14:01Z")

</div>

PyPi. I ran into problems trying to install from git, but I’ll try again and report back. Thanks.

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 2, 2024, 11:28pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/4 "2024-12-02T23:28:37Z")

</div>

what issue? lmk if i can help

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 3, 2024, 3:52pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/5 "2024-12-03T15:52:55Z")

</div>

I need to check my notes, as it was a week or two ago, but I will definitely try soon and come back with updates. Thanks so much for your assistance!

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 3, 2024, 8:05pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/6 "2024-12-03T20:05:56Z")

</div>

Alright. I tried to install through git again and this time it worked! However now I’m trying to find guidance on how to actually connect to and initialize an Agilent VSpin centrifuge.

I can load the specific module, but I’m getting to an error here:

> $ from pylabrobot.centrifuge import Centrifuge, VSpin  
> $ cf = Centrifuge(name = ‘centrifuge’, backend = VSpin(bucket\_1\_position=0), size\_x= 1, size\_y=1, size\_z=1)  
> Traceback (most recent call last):  
> File “”, line 1, in   
> File “C:\Users\gross001\Projects\Pylabrobot\pylabrobot\pylabrobot\centrifuge\vspin.py”, line 34, in **init**  
> self.dev = Device(lazy\_open=True, device\_id=device\_id)  
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  
> File “C:\Users\gross001\Projects\Pylabrobot\env\Lib\site-packages\pylibftdi\device.py”, line 201, in **init**  
> self.fdll = self.driver.fdll  
> ^^^^^^^^^^^^^^^^  
> File “C:\Users\gross001\Projects\Pylabrobot\env\Lib\site-packages\pylibftdi\driver.py”, line 192, in fdll  
> self.\_fdll = self.\_load\_library(“libftdi”)  
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  
> File “C:\Users\gross001\Projects\Pylabrobot\env\Lib\site-packages\pylibftdi\driver.py”, line 151, in \_load\_library  
> raise LibraryMissingError(  
> pylibftdi.\_base.LibraryMissingError: libftdi library not found (search: [‘ftdi1’, ‘libftdi1’, ‘ftdi’, ‘libftdi’])  
> $

The key error here appears to be **LibraryMissingError**  
**pylibftdi.\_base.LibraryMissingError: libftdi library not found (search: [‘ftdi1’, ‘libftdi1’, ‘ftdi’, ‘libftdi’])**

Any idea what this means? Thanks.

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 3, 2024, 11:48pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/7 "2024-12-03T23:48:45Z")

</div>

great to hear plr now runs!

sorry about the lack of documentation on installation for the centrifuge. i have yet to update it.

there are two things to do on windows:

1. install libftdi. this is a library needed to communicate with the device  
a. download the libftdi dlls from here: [picusb - Browse Files at SourceForge.net](https://sourceforge.net/projects/picusb/files/). i got this one: [libftdi1-1.5\_devkit\_x86\_x64\_19July2020.zip](https://sourceforge.net/projects/picusb/files/libftdi1-1.5_devkit_x86_x64_19July2020.zip/download) (download link)  
b. in your virtualenv, look for the Scripts folder.  
c. copy the dlls named “libftdi1.dll” and “libusb-1.0.dll” into the python/dlls folder (in the bin64 folder) into the Scripts folder.

2. use zadig to replace the driver of the device you are using with libusbk. i have instructions for this on the website: [Installation — PyLabRobot documentation](https://docs.pylabrobot.org/user_guide/installation.html#installing). substitute ‘ml\_star’ with agilent centrifuge. happy to help if you have questions

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 4, 2024, 9:51pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/8 "2024-12-04T21:51:28Z")

</div>

This is very helpful.

I did step 1 and tested the command. I’m no longer getting the missing library error from before!

I haven’t yet attempted step 2, as I’m concerned about modifying my USB-related drivers. Is it safe? I’m worried some USB device might behave differently and I won’t know how to change it back.

I really appreciate your help, and I’d be happy to compose some documentation if you can help me get to the point where I can issue commands to the centrifuge and loader. Is there are rough starting guide of any kind? This is as far as I’ve gotten so far:

> $ cf = Centrifuge(name = ‘centrifuge’, backend = VSpin(bucket\_1\_position=0), size\_x= 1, size\_y=1, size\_z=1)  
> Traceback (most recent call last):  
> File “”, line 1, in   
> TypeError: Centrifuge. **init** () got an unexpected keyword argument ‘name’

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 4, 2024, 10:08pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/9 "2024-12-04T22:08:03Z")

</div>

> [@andrewrgross](#):
>
> Is it safe?

yes, very easily reversible (see instructions on the same page) i have done it many times

if you’re worried, you could consider getting a dedicated computer (i use $50 raspberry pis for all plr work, works great)

> [@andrewrgross](#):
>
> This is as far as I’ve gotten so far:

Apologies, the code should be

```python
from pylabrobot.centrifuge import Centrifuge, VSpin
cf = Centrifuge(backend=VSpin(bucket_1_position=0))
await cf.setup()

await cf.start_spin_cycle(g = 800, duration = 60)

```

fixed with [fix centrifuge example · PyLabRobot/pylabrobot@929fafd · GitHub](https://github.com/PyLabRobot/pylabrobot/commit/929fafdaa5447cf0437739abb76ffedd64c14360)

after this it should work 🤞

> [@andrewrgross](#):
>
> Is there are rough starting guide of any kind?

there is a tiny bit of documentation here: [Centrifuges — PyLabRobot documentation](https://docs.pylabrobot.org/user_guide/centrifuge.html), but it wouldn’t hurt to expand that 😉

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 12, 2024, 4:17pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/10 "2024-12-12T16:17:18Z")

</div>

Once again, thank you so much for the quick and specific response.

I’ve gotten the basic module loaded, and I see the commands running it. But how do I specify the USB serial ports to use for the centrifuge and loader?

Thanks.

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 12, 2024, 5:51pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/11 "2024-12-12T17:51:42Z")

</div>

`python -m pylibftdi.examples.list_devices` to find device ids. unplug one or the other to see which is which. then pass the corresponding id in the `device_id` param to `VSpin` and `Access2`.

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 12, 2024, 5:53pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/12 "2024-12-12T17:53:02Z")

</div>

earlier this week i added resource modeling to the centrifuge and loader. when i finish my other project (hope today) I will write a tutorial for the docs. ([centrifuge + loader resource modelling by rickwierenga · Pull Request #334 · PyLabRobot/pylabrobot · GitHub](https://github.com/PyLabRobot/pylabrobot/pull/334))

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 13, 2024, 5:23pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/13 "2024-12-13T17:23:05Z")

</div>

This is all amazing. I’ll try it out and get back to you.

I’m a field service engineer for Agilent (who makes this centrifuge and loader), so I don’t actually have a centrifuge available each day, just when I encounter them in the wild. But I should get a chance today.

Also, is there a way I can contribute to this? I’m very enthusiastic about writing and editing documentation for this kind of project.

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 13, 2024, 8:30pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/14 "2024-12-13T20:30:56Z")

</div>

dude, that’s fantastic!

more documentation is always a great contribution, and this thread is one of the embarrassing examples showing why. we don’t have installation instructions for the vspin up to date. If you’re feeling super motivated, a consolidated version of this thread would be super nice as an addition to the [installation guide](https://docs.pylabrobot.org/user_guide/installation.html). The docs are all markdown/notebooks and there is an “Edit on GitHub” link right on every docs page 😉

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [December 21, 2024, 12:37am UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/15 "2024-12-21T00:37:12Z")

</div>

> [@rickwierenga](#):
>
> `python -m pylibftdi.examples.list_devices` to find device ids. unplug one or the other to see which is which. then pass the corresponding id in the `device_id` param to `VSpin` and `Access2`.

I’ll do it! If I get this working, I’ll definitely write up a guide.

Do you have any advice on getting involved with the project? Are there any other developers, and do you hold any developer meetings or office hours when I could discuss the project?

I’ll be a little out of contact during the holidays, but after I get back I’d like to keep this conversation going, and see how I can contribute.

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [December 21, 2024, 1:37am UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/16 "2024-12-21T01:37:20Z")

</div>

thanks in advance! and no pressure, ever. & happy holidays!

> [@andrewrgross](#):
>
> Do you have any advice on getting involved with the project?

make PRs on github and post on the forum! there is no secret 😉

> [@andrewrgross](#):
>
> Are there any other developers, and do you hold any developer meetings or office hours when I could discuss the project?

we had a developer meeting once almost a year ago, but i think the conclusion at that time was that asynchronous communication on github/the forum is more productive. But if there’s interest (we have grown the number of developers/users quite a bit since then) I’d be happy to organize another one to see how people feel. I will make a new post about it.

I guess I am the benevolent dictator of the project, but plr is obviously developed by many people (check the github page). You can recognize developers on the forum by their tag (i apply this tag when someone has a merged PR). Camillo @CamilloMoschner has a special tag. To ‘meet’ people, just continue making posts and people will respond 🙂 it’s all just chill

---

<div class="post-metadata">

**Author:** ![ben](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/ben/32/41_2.png) [@ben](https://discuss.pylabrobot.org/u/ben)\
**Post date:** [December 23, 2024, 2:20am UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/17 "2024-12-23T02:20:37Z")

</div>

i made a more in-depth [tutorial](https://github.com/PyLabRobot/pylabrobot/blob/0a1f33be6004d3849951f43781c6821b95ce431f/docs/user_guide/centrifuge.md#guide-to-using-zadig-for-the-vspin-centrifuge) PR after getting this to work myself - super easy to reverse!

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [January 8, 2025, 12:27am UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/18 "2025-01-08T00:27:08Z")

</div>

I really appreciate this!

It looks good. I have to wait until the next time I encounter a centrifuge to test the serial address lookup method, but in the meantime perhaps you can help with this: the command

> from pylabrobot import Centrifuge

Elicits the error _“ImportError: cannot import name ‘Centrifuge’ from ‘pylabrobot’ (unknown location)”_

Also

> from pylabrobot.backends.vspin import VSpin

Elicits _"ModuleNotFoundError: No module named ‘pylabrobot.backends’ "_

This is on Windows 11 running on Spyder. I can import pylabrobot successfully. Do you have any advice?

---

<div class="post-metadata">

**Author:** ![rickwierenga](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/rickwierenga/32/963_2.png) [@rickwierenga](https://discuss.pylabrobot.org/u/rickwierenga)\
**Post date:** [January 8, 2025, 7:44pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/19 "2025-01-08T19:44:28Z")

</div>

o oh the docs were wrong 😳 apologies

```python
from pylabrobot.centrifuge import Centrifuge, VSpin

# Replace with your specific FTDI device ID and bucket position for profile in Agilent Centrifuge Config Tool.
backend = VSpin(bucket_1_position=6969, device_id="XXXXXXXX")
centrifuge = Centrifuge(
   backend=backend,
   name="centrifuge",
   size_x=1, size_y=1, size_z=1
)

# Initialize the centrifuge.
await centrifuge.setup()

```

fixed with [Update centrifuge.md · PyLabRobot/pylabrobot@079bcc1 · GitHub](https://github.com/PyLabRobot/pylabrobot/commit/079bcc1b118d6dd6764285366caf1e7c86e75e07), takes about 45 min to update on the website

---

<div class="post-metadata">

**Author:** ![andrewrgross](https://discuss.pylabrobot.org/user_avatar/discuss.pylabrobot.org/andrewrgross/32/90_2.png) [@andrewrgross](https://discuss.pylabrobot.org/u/andrewrgross)\
**Post date:** [March 18, 2025, 7:49pm UTC](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85/20 "2025-03-18T19:49:37Z")

</div>

Hi! Sorry that it’s been a minute, but I’m back to trying to get this working.

I’ve installed PyLabRobot and I can import it. But I cannot import pylabrobot.centrifuge.

> import pylabrobot.centrifuge

and

> from pylabrobot.centrifuge import Centrifuge, VSpin

elicits "ModuleNotFoundError: No module named ‘pylabrobot.centrifuge’ "

Any advice? Also, how do I format text as code the way you did in this forum? Thanks.

[Next page](https://discuss.pylabrobot.org/t/getting-started-and-encountering-modulenotfounderror/85.md?page=2)
