diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml
index 53dfd24..d76fdc6 100644
--- a/.github/workflows/cd.yml
+++ b/.github/workflows/cd.yml
@@ -37,7 +37,7 @@ jobs:
curl -sSO https://www.mersenne.org/favicon.ico
pyinstaller -F -i favicon.ico primenet.py
./dist/primenet --help
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
with:
name: PrimeNet_Windows_${{ matrix.architecture }}
path: |
@@ -50,7 +50,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- - uses: actions/download-artifact@v3
+ - uses: actions/download-artifact@v4
- name: Install
run: |
sudo apt-get -yqq update
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 909cb5d..3a47ffb 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -30,7 +30,7 @@ jobs:
gcc --version
- name: Script
run: bash -e -o pipefail -- cudalucas.sh ANONYMOUS
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
if: always()
with:
name: ${{ matrix.os }}_cudalucas
@@ -68,10 +68,10 @@ jobs:
$CXX --version
- name: Script
run: bash -e -o pipefail -- gpuowl.sh ANONYMOUS
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
if: always()
with:
- name: ${{ matrix.os }}_gpuowl
+ name: ${{ matrix.os }}_${{ matrix.cxx }}_gpuowl
path: |
gpuowl/
- name: ShellCheck
@@ -121,7 +121,7 @@ jobs:
echo -e '## Clang-Tidy\n```' >> $GITHUB_STEP_SUMMARY
grep 'warning:' clang-tidy.log | sed 's/\x1B\[\([0-9]\+\(;[0-9]\+\)*\)\?m//g' | awk '{ print $NF }' | sort | uniq -c | sort -nr >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
- - uses: actions/upload-artifact@v3
+ - uses: actions/upload-artifact@v4
if: always()
with:
name: ${{ matrix.os }}_${{ matrix.cc }}_mlucas
diff --git a/google-colab/Colab CPU MPrime.ipynb b/google-colab/Colab CPU MPrime.ipynb
index e6d3f07..75f8d5c 100644
--- a/google-colab/Colab CPU MPrime.ipynb
+++ b/google-colab/Colab CPU MPrime.ipynb
@@ -7,7 +7,7 @@
"id": "view-in-github"
},
"source": [
- "
(1 - Recommend). Create and save new notebook(s) to enable automatic re-mounting of Drive storage. Copy and paste the below code into a new notebook in Colab and follow the directions in the How To Use section of the README
(2). Open the pre-formed version in Colab (requires manual authorization each time a notebook is opened)
"
+ "(1 - Recommend). Create and save new notebook(s) to enable automatic re-mounting of Drive storage. Copy and paste the below code into a new notebook in Colab and follow the directions in the How To Use section of the README
(2). Open the pre-formed version in Colab (requires manual authorization each time a notebook is opened)
"
]
},
{
@@ -39,7 +39,7 @@
"#@markdown 6 | 0.372 | 0.745 | 1.117 | 1.49 | 1.862 | 2.235 | 2.475\n",
"#@markdown 7 | 0.745 | 1.49 | 2.235 | *2.98* | *3.725* | *4.47* | *4.95*\n",
"#@markdown 8 | 1.49 | *2.98* | *4.47* | 5.96 | 7.45 | 8.94 | 9.9\n",
- "#@markdown 9 | ***2.98*** | **5.96** | 8.94 | 11.9 | 14.9 | 17.88 | 19.8\n",
+ "#@markdown 9 | ***2.98*** | **5.96** | 8.94 | 11.92 | 14.9 | 17.88 | 19.8\n",
"#@markdown 10 | 5.96 | 11.92 | **17.88** | **23.84** | **29.8** | **35.76** | **39.6**\n",
"#@markdown 11 | 11.92 | 23.84 | 35.76 | 47.68 | 59.6 | 71.52 | 79.2\n",
"#@markdown 12 | 23.84 | 47.68 | 71.52 | 95.36 | 119.2 | 143 | 158.4\n",
@@ -91,7 +91,7 @@
" '''Download/Install/Configure Prime95.'''\n",
" !wget -nv -O master.zip https://github.com/tdulcet/Distributed-Computing-Scripts/archive/master.zip\n",
" !unzip -o master.zip\n",
- " print('Downloading and setting up Prime95\\n')\n",
+ " print('\\nDownloading and setting up Prime95\\n')\n",
" !cp Distributed-Computing-Scripts-master/{mprime2.sh,mprime2.exp,idletime.sh} .\n",
" !sed -i 's/\"mprime\"/\"mprime_cpu\"/' mprime2.sh # Name the folder specific to the runtime type\n",
" !sed -i '/^\\.\\/mprime / s/^/echo \"Skipped\" # /' mprime2.sh # Do not start Prime95\n",
diff --git a/google-colab/Colab GPU CUDALucas.ipynb b/google-colab/Colab GPU CUDALucas.ipynb
index a22cc86..7c66bea 100644
--- a/google-colab/Colab GPU CUDALucas.ipynb
+++ b/google-colab/Colab GPU CUDALucas.ipynb
@@ -7,7 +7,7 @@
"id": "view-in-github"
},
"source": [
- "(1 - Recommend). Create and save new notebook(s) to enable automatic re-mounting of Drive storage. Copy and paste the below code into a new notebook in Colab and follow the directions in the How To Use section of the README
(2). Open the pre-formed version in Colab (requires manual authorization each time a notebook is opened)
"
+ "(1 - Recommend). Create and save new notebook(s) to enable automatic re-mounting of Drive storage. Copy and paste the below code into a new notebook in Colab and follow the directions in the How To Use section of the README
(2). Open the pre-formed version in Colab (requires manual authorization each time a notebook is opened)
"
]
},
{
@@ -41,7 +41,7 @@
"#@markdown 6 | 0.372 | 0.745 | 1.117 | 1.49 | 1.862 | 2.235 | 2.475\n",
"#@markdown 7 | 0.745 | 1.49 | 2.235 | *2.98* | *3.725* | *4.47* | *4.95*\n",
"#@markdown 8 | 1.49 | *2.98* | *4.47* | 5.96 | 7.45 | 8.94 | 9.9\n",
- "#@markdown 9 | ***2.98*** | **5.96** | 8.94 | 11.9 | 14.9 | 17.88 | 19.8\n",
+ "#@markdown 9 | ***2.98*** | **5.96** | 8.94 | 11.92 | 14.9 | 17.88 | 19.8\n",
"#@markdown 10 | 5.96 | 11.92 | **17.88** | **23.84** | **29.8** | **35.76** | **39.6**\n",
"#@markdown 11 | 11.92 | 23.84 | 35.76 | 47.68 | 59.6 | 71.52 | 79.2\n",
"#@markdown 12 | 23.84 | 47.68 | 71.52 | 95.36 | 119.2 | 143 | 158.4\n",
@@ -103,20 +103,21 @@
" !wget -nv -O master.zip https://github.com/tdulcet/Distributed-Computing-Scripts/archive/master.zip\n",
" !unzip -o master.zip\n",
"\n",
- " print('Downloading, building and setting up CUDALucas\\n')\n",
+ " print('\\nDownloading, building and setting up CUDALucas\\n')\n",
" !cp Distributed-Computing-Scripts-master/{cudalucas2.sh,primenet.py,idletime.sh} .\n",
" !sed -i '/^GPU=/,/^fi/ s/^/# /' cudalucas2.sh # Do not check for an Nvidia GPU\n",
" !sed -i '/^[[:blank:]]*if ! COMPUTE=/,/^[[:blank:]]*fi/!b; /^[[:blank:]]*fi/a echo \"$COMPUTE\"' cudalucas2.sh # Output CUDA compute capability of GPU\n",
" !sed -i 's/\\/$COMPUTE/\\/-gencode arch=compute_50,code=sm_50 -gencode arch=compute_60,code=sm_60 -gencode arch=compute_70,code=sm_70 -gencode arch=compute_75,code=sm_75 -gencode arch=compute_80,code=sm_80/' cudalucas2.sh\n",
" !sed -i '/^\\.\\/CUDALucas / s/^/# /' cudalucas2.sh # Disable optimization step for faster install\n",
+ " !sed -i '/^timeout / s/^/echo \"Skipped\" # /' cudalucas2.sh # Disable optimization step for faster install\n",
" !sed -i '/^nohup / s/^/echo \"Skipped\" # /' cudalucas2.sh # Do not start PrimeNet\n",
" !sed -i '/^python3 -OO / s/^/echo \"Skipped\" # /' cudalucas2.sh # Do not start PrimeNet\n",
" !bash -- cudalucas2.sh {computer_number} '{prime_ID}' '{computer_name}' {GPU_type_of_work}\n",
- " print('Registering computer with PrimeNet\\n')\n",
+ " print('\\nRegistering computer with PrimeNet\\n')\n",
" !cd cudalucas && python3 -OO primenet.py -t 0 --checkin 1 -W 1 -T {GPU_type_of_work} -u '{prime_ID}' -i '{'worktodo' + computer_number + '.txt'}' -r '{'results' + computer_number + '.txt'}' -l '{'local' + computer_number + '.ini'}' --cudalucas '{'gpu' + computer_number + '.out'}' -H '{computer_name}'\n",
" !cp -u Distributed-Computing-Scripts-master/google-colab/gpu_optimizations/* cudalucas/\n",
"\n",
- " print('Downloading and setting up Prime95\\n')\n",
+ " print('\\nDownloading and setting up Prime95\\n')\n",
" !cp Distributed-Computing-Scripts-master/{mprime2.sh,mprime2.exp} .\n",
" !sed -i 's/\"mprime\"/\"mprime_gpu\"/' mprime2.sh # Name the folder specific to the runtime type\n",
" !sed -i '/^\\.\\/mprime / s/^/echo \"Skipped\" # /' mprime2.sh # Do not start Prime95\n",
diff --git a/google-colab/Colab GPU GpuOwl.ipynb b/google-colab/Colab GPU GpuOwl.ipynb
index 99f0c79..ba817de 100644
--- a/google-colab/Colab GPU GpuOwl.ipynb
+++ b/google-colab/Colab GPU GpuOwl.ipynb
@@ -7,7 +7,7 @@
"id": "view-in-github"
},
"source": [
- "(1 - Recommend). Create and save new notebook(s) to enable automatic re-mounting of Drive storage. Copy and paste the below code into a new notebook in Colab and follow the directions in the How To Use section of the README
(2). Open the pre-formed version in Colab (requires manual authorization each time a notebook is opened)
"
+ "(1 - Recommend). Create and save new notebook(s) to enable automatic re-mounting of Drive storage. Copy and paste the below code into a new notebook in Colab and follow the directions in the How To Use section of the README
(2). Open the pre-formed version in Colab (requires manual authorization each time a notebook is opened)
"
]
},
{
@@ -42,7 +42,7 @@
"#@markdown 6 | 0.372 | 0.745 | 1.117 | 1.49 | 1.862 | 2.235 | 2.475\n",
"#@markdown 7 | 0.745 | 1.49 | 2.235 | *2.98* | *3.725* | *4.47* | *4.95*\n",
"#@markdown 8 | 1.49 | *2.98* | *4.47* | 5.96 | 7.45 | 8.94 | 9.9\n",
- "#@markdown 9 | ***2.98*** | **5.96** | 8.94 | 11.9 | 14.9 | 17.88 | 19.8\n",
+ "#@markdown 9 | ***2.98*** | **5.96** | 8.94 | 11.92 | 14.9 | 17.88 | 19.8\n",
"#@markdown 10 | 5.96 | 11.92 | **17.88** | **23.84** | **29.8** | **35.76** | **39.6**\n",
"#@markdown 11 | 11.92 | 23.84 | 35.76 | 47.68 | 59.6 | 71.52 | 79.2\n",
"#@markdown 12 | 23.84 | 47.68 | 71.52 | 95.36 | 119.2 | 143 | 158.4\n",
@@ -112,7 +112,7 @@
" !wget -nv -O master.zip https://github.com/tdulcet/Distributed-Computing-Scripts/archive/master.zip\n",
" !unzip -o master.zip\n",
"\n",
- " print('Downloading, building and setting up GpuOwl\\n')\n",
+ " print('\\nDownloading, building and setting up GpuOwl\\n')\n",
" !cp Distributed-Computing-Scripts-master/{gpuowl2.sh,primenet.py,idletime.sh,gpuowl-bench.sh,gpuowl-wrapper.sh} .\n",
" !sed -i '/^GPU=/,/^fi/ s/^/# /' gpuowl2.sh # Do not check for an GPU\n",
" !sed -i '/^if command -v clinfo/,/^fi/ s/^/# /' gpuowl2.sh # Do not check for clinfo\n",
@@ -125,10 +125,10 @@
" !sed -i '/^ARGS3=/a \\\\t-jacobi 100000' '{file}'\n",
" !sed -i '/^ARGS1=/a \\\\t-mprimeDir ../../mprime_gpu' '{file}'\n",
" !sed -i 's/0.9/0.95/' '{file}' # Use up to 95% of GPU RAM\n",
- " print('Registering computer with PrimeNet\\n')\n",
+ " print('\\nRegistering computer with PrimeNet\\n')\n",
" !cd '{'gpuowl/' + computer_number}' && python3 -OO ../primenet.py -t 0 --checkin 1 -W 1 -T {GPU_type_of_work} -u '{prime_ID}' -i 'worktodo.ini' -r 'results.ini' -g -H '{computer_name}'\n",
"\n",
- " print('Downloading and setting up Prime95\\n')\n",
+ " print('\\nDownloading and setting up Prime95\\n')\n",
" !cp Distributed-Computing-Scripts-master/{mprime2.sh,mprime2.exp} .\n",
" !sed -i 's/\"mprime\"/\"mprime_gpu\"/' mprime2.sh # Name the folder specific to the runtime type\n",
" !sed -i '/^\\.\\/mprime / s/^/echo \"Skipped\" # /' mprime2.sh # Do not start Prime95\n",
diff --git a/google-colab/README.md b/google-colab/README.md
index c1ec7c4..8f34aa5 100644
--- a/google-colab/README.md
+++ b/google-colab/README.md
@@ -7,15 +7,15 @@ This repository contains two Jupyter Notebooks, a “CPU” only notebook (`Cola
Each notebook makes use of Google Drive storage, which is provided to all Google accounts. See here for a [“TPU” only notebook](https://github.com/TPU-Mersenne-Prime-Search/TensorPrime/wiki/Usage-and-Arguments) which runs TensorPrime.
> [!IMPORTANT]
-> The “GPU and CPU” notebook does not currently work, as [OpenCL is broken on Colab](https://github.com/googlecolab/colabtools/issues/3592) and GpuOwl uses OpenCL. Users can temporarily switch back to the older version of the notebook [`Colab GPU CUDALucas.ipynb`](Colab GPU CUDALucas.ipynb), which runs CUDALucas. CUDALucas is slower than GpuOwl, but it uses CUDA, which still works on Colab.
+> The “GPU and CPU” notebook does not currently work, as [OpenCL is broken on Colab](https://github.com/googlecolab/colabtools/issues/3592) and GpuOwl uses OpenCL. Users can temporarily switch back to the older version of the notebook [`Colab GPU CUDALucas.ipynb`](Colab%20GPU%20CUDALucas.ipynb), which runs CUDALucas. CUDALucas is slower than GpuOwl, but it uses CUDA, which still works on Colab.
## How to Use
**Please Note:** you must keep each notebook **OPEN** in your browser to prevent it from disconnecting due to being perceived as idle. [Pin the tab(s)](https://support.mozilla.org/en-US/kb/pinned-tabs-keep-favorite-websites-open) or move them to a dedicated window for easy access to your notebook(s).
-1. **Choose a Persistent Storage Option** Recommend Method: Copy the source of our respective [“GPU and CPU” notebook](Colab GPU GpuOwl.ipynb) and/or [“CPU” notebook](Colab CPU MPrime.ipynb), pasting them into one or more [new notebooks](http://colab.research.google.com/#create=true) in Colab. Then, uniquely name and save the notebook(s) (Ctrl + s). Then, on the far left, click “📁”, the “Mount Drive” folder button and select “CONNECT TO GOOGLE DRIVE”. Your Drive storage should automatically remount each time you run the notebook(s). You may need to repeat this last part after a while. See the official [video](https://video.twimg.com/tweet_video/EQbtltjVAAA2qTs.mp4) for a walkthrough.
+1. **Choose a Persistent Storage Option** Recommend Method: Copy the source of our respective [“GPU and CPU” notebook](Colab%20GPU%20GpuOwl.ipynb) and/or [“CPU” notebook](Colab%20CPU%20MPrime.ipynb), pasting them into one or more [new notebooks](http://colab.research.google.com/#create=true) in Colab. Then, uniquely name and save the notebook(s) (Ctrl + s). Then, on the far left, click “📁”, the “Mount Drive” folder button and select “CONNECT TO GOOGLE DRIVE”. Your Drive storage should automatically remount each time you run the notebook(s). You may need to repeat this last part after a while. See the official [video](https://video.twimg.com/tweet_video/EQbtltjVAAA2qTs.mp4) for a walkthrough.
Alternative Method
- Open “GPU and CPU” notebook: and/or the “CPU” only notebook: in Colab. Then, uniquely name and save a copy to your Drive (Ctrl + s) to avoid a warning each time you run the notebook. *WARNINGS*: This method will continually require an authorization step each time you run the notebook(s). After step 4 below, follow the link Google provides to authorize the login to your Drive and copy-and-paste the authorization string into the textbox Google provides within the notebook's output box.
+ Open “GPU and CPU” notebook: and/or the “CPU” only notebook: in Colab. Then, uniquely name and save a copy to your Drive (Ctrl + s) to avoid a warning each time you run the notebook. *WARNINGS*: This method will continually require an authorization step each time you run the notebook(s). After step 4 below, follow the link Google provides to authorize the login to your Drive and copy-and-paste the authorization string into the textbox Google provides within the notebook's output box.
2. **If Running the GPU** notebook, you must enable the GPU runtime. On the upper left, click “Runtime” → “Change runtime type”, under “Hardware accelerator” select “GPU” and click “SAVE”.
@@ -47,7 +47,7 @@ Proof Power | Exp 50M | Exp 100M | Exp 150M | Exp 200M | Exp 250M | Exp 300M | E
6 | 0.372 | 0.745 | 1.117 | 1.49 | 1.862 | 2.235 | 2.475 | 7.45
7 | 0.745 | 1.49 | 2.235 | *2.98* | *3.725* | *4.47* | *4.95* | 14.9
8 | 1.49† | *2.98*† | *4.47*† | 5.96† | 7.45† | 8.94† | 9.9† | 29.8†
-9 | ***2.98*** | **5.96** | 8.94 | 11.9 | 14.9 | 17.88 | 19.8 | 59.6
+9 | ***2.98*** | **5.96** | 8.94 | 11.92 | 14.9 | 17.88 | 19.8 | 59.6
10 | 5.96 | 11.92 | **17.88** | **23.84** | **29.8** | **35.76** | **39.6** | 119.2
11 | 11.92 | 23.84 | 35.76 | 47.68 | 59.6 | 71.52 | 79.2 | **238.4**
12 | 23.84 | 47.68 | 71.52 | 95.36 | 119.2 | 143 | 158.4 | 476.8
@@ -65,22 +65,22 @@ Proof Power | Proof Power Multiplier | Certification Cost | Exp 50M | Exp 100M |
\- | 3 | 1⁄256 | 125.1 | 250.3 | 375.5 | 500.6 | 625.8 | 751 | 831.6 | 2503
\- | 4 | 1⁄512 | 166.8 | 333.7 | 500.6 | 667.5 | 834.4 | 1001 | 1108 | 3337
7 | 1 | 1⁄128 | 47.68 | 95.36 | 143 | 190.7 | 238.4 | 286.1 | 316.8 | 953.6
-\- | 2 | 1⁄256 | 95.36 | 190.7 | 286.1 | *381.4* | *476.8* | *572.2* | *633* | 1907
-\- | 3 | 1⁄512 | 143 | 286.1 | 429.1 | 572.2 | 715.2 | 858.3 | 950 | 2861
+\- | 2 | 1⁄256 | 95.36 | 190.7 | 286.1 | *381.4* | *476.8* | *572.2* | *633.6* | 1907
+\- | 3 | 1⁄512 | 143 | 286.1 | 429.1 | 572.2 | 715.2 | 858.3 | 950.4 | 2861
\- | 4 | 1⁄1024 | 190.7 | 381.4 | 572.2 | 762.9 | 953.6 | 1144 | 1267 | 3814
-8 | 1 | 1⁄256 | 53.6† | *107.2*† | *160.9*† | 214.5† | 268.2† | 321.8† | 356.4† | 1072†
+8 | 1 | 1⁄256 | 53.64† | *107.2*† | *160.9*† | 214.5† | 268.2† | 321.8† | 356.4† | 1072†
\- | 2 | 1⁄512 | 107.2 | 214.5 | 321.8 | 429.1 | 536.4 | 643.7 | 712.8 | 2145
\- | 3 | 1⁄1024 | 160.9 | 321.8 | 482.7 | 643.7 | 804.6 | 965.5 | 1069 | 3218
\- | 4 | 1⁄2048 | 214.5 | 429.1 | 643.7 | 858.3 | 1072.8 | 1287 | 1425 | 4291
9 | 1 | 1⁄512 | ***59.6*** | **119.2** | 178.8 | 238.4 | 298 | 357.6 | 396 | 1192
\- | 2 | 1⁄1024 | 119.2 | 238.4 | 357.6 | 476.8 | 596 | 715.2 | 792 | 2384
\- | 3 | 1⁄2048 | 178.8 | 357.6 | 536.4 | 715.2 | 894 | 1072 | 1188 | 3576
-\- | 4 | 1⁄4096 | 238.4 | 476.8 | 715.2 | 953.6 | 1192 | 1430 | 19.8 | 4768
-10 | 1 | 1⁄1024 | 65.56 | 131.1 | **196.6** | **262.2** | **327.82** | **393.3** | **1584** | 1311
-\- | 2 | 1⁄2048 | 131.1 | 262.2 | 393.3 | 524.5 | 655.6 | 786.7 | 435.6 | 2622
-\- | 3 | 1⁄4096 | 196.6 | 393.3 | 590 | 786.7 | 983.4 | 1180 | 871.2 | 3933
-11 | 1 | 1⁄2048 | 71.52 | 143 | 214.5 | 286.1 | 357.6 | 429.1 | 1742 | **1430**
-\- | 2 | 1⁄4096 | 143 | 286.1 | 429.1 | 572.2 | 715.2 | 858.3 | 475.2 | 2861
+\- | 4 | 1⁄4096 | 238.4 | 476.8 | 715.2 | 953.6 | 1192 | 1430 | 1584 | 4768
+10 | 1 | 1⁄1024 | 65.56 | 131.1 | **196.6** | **262.2** | **327.8** | **393.3** | **435.6** | 1311
+\- | 2 | 1⁄2048 | 131.1 | 262.2 | 393.3 | 524.5 | 655.6 | 786.7 | 871.2 | 2622
+\- | 3 | 1⁄4096 | 196.6 | 393.3 | 590 | 786.7 | 983.4 | 1180 | 1306 | 3933
+11 | 1 | 1⁄2048 | 71.52 | 143 | 214.5 | 286.1 | 357.6 | 429.1 | 475.2 | **1430**
+\- | 2 | 1⁄4096 | 143 | 286.1 | 429.1 | 572.2 | 715.2 | 858.3 | 950.4 | 2861
12 | 1 | 1⁄4096 | 77.48 | 154.9 | 232.4 | 309.9 | 387.4 | 464.9 | 514.8 | 1549
*Italic* - Prime95 default proof power and multiplier, uses a maximum of 6 GB (5.587 GiB) per exponent\
diff --git a/gpuowl-bench.sh b/gpuowl-bench.sh
index 107aa17..7dfbb4f 100644
--- a/gpuowl-bench.sh
+++ b/gpuowl-bench.sh
@@ -69,8 +69,8 @@ fi
output=$("$GPUOWL" -h)
if echo "$output" | grep -q '^-unsafeMath'; then
-# elif echo "$output" | grep -q '^-safeMath'; then
ARGS+=(-unsafeMath)
+# elif echo "$output" | grep -q '^-safeMath'; then
# ARGS+=( -safeMath )
fi
diff --git a/mprime-python-port/mprime.py b/mprime-python-port/mprime.py
index 84689ae..7fc91ef 100644
--- a/mprime-python-port/mprime.py
+++ b/mprime-python-port/mprime.py
@@ -7,9 +7,9 @@
import hashlib # sha256
import os
+import platform
import re # regular expression matching
import shlex
-import socket
import stat
import subprocess
import sys
@@ -43,7 +43,7 @@ def sha256sum(filename):
# Main script
USERID = sys.argv[1] if len(sys.argv) > 1 else os.environ["USER"]
-COMPUTER = sys.argv[2] if len(sys.argv) > 2 else socket.gethostname()
+COMPUTER = sys.argv[2] if len(sys.argv) > 2 else platform.node()
TYPE = sys.argv[3] if len(sys.argv) > 3 else str(150)
TIME = (int(sys.argv[4]) if len(sys.argv) > 4 else 10) * 60