# Retrieving mworks events in a linux python environment

**URL:** <https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026>\
**Category:** Support\
**Created:** [August 28, 2024, 5:38pm UTC](https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026 "2024-08-28T17:38:25Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ggaziv](https://avatars.discourse-cdn.com/v4/letter/g/96bed5/32.png) [@ggaziv](https://mworks.discourse.group/u/ggaziv)\
**Post date:** [August 28, 2024, 5:38pm UTC](https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026/1 "2024-08-28T17:38:25Z")

</div>

Hi Chris,

I am trying to use mworks code to get events from .mwk2 files.  
I found [this page](https://mworks.github.io/documentation/latest/guide/data_analysis.html) about analysis requiring the following line to be add to interface with mworks code:

```auto
import sys
sys.path.insert(0, '/Library/Application Support/MWorks/Scripting/Python')

```

However I’m trying to work in our cluster linux environment where this path probably doesn’t apply? Also I couldn’t find instructions on how to install mworks in this environment.  
I also cloned the github repo and found the following path to possibly be similar to the above. Added to sys as follows:

```
sys.path.insert(0, '/home/guyga/projects/mworks/tools/python/Modules')

```

But this doesn’t actually work:  
 ![image](https://canada1.discourse-cdn.com/flex031/uploads/mworks/original/1X/ab41c088069817b12883db7a05b53e4f615327cd.png)

Please advise.

Thanks,  
Guy

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [August 28, 2024, 6:06pm UTC](https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026/2 "2024-08-28T18:06:27Z")

</div>



---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [August 28, 2024, 6:12pm UTC](https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026/3 "2024-08-28T18:12:07Z")

</div>



---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [August 28, 2024, 6:16pm UTC](https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026/4 "2024-08-28T18:16:28Z")

</div>

Hi Guy,

MWorks’ standard data tools don’t run on non-Apple platforms. However, there is an alternative, [pure-Python MWK2 reader](https://raw.githubusercontent.com/mworks/mworks/master/tools/python/Modules/mwk2reader.py) that you can use. For more info, please see [this discussion](https://mworks.discourse.group/t/analyze-mworks-on-linux/873/4).

Cheers,  
Chris

---

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [September 3, 2024, 1:49pm UTC](https://mworks.discourse.group/t/retrieving-mworks-events-in-a-linux-python-environment/1026/5 "2024-09-03T13:49:53Z")

</div>


