I’ve decided to release one of my simpler scripts for measuring CPU performance on the various whitelisted (and greylisted) BOINC projects. I’ve spent a couple days fixing bugs, making the output more presentable, and increasing the fault tolerance of the code.
As some of you may know I’ve also been working on a slightly more accurate method based on completed task data. However I decided that given the connection difficulties with ODLK1, I should not publicly release a script which requests many web pages from the project sites simultaneously and repeatedly, at least at this time. A side benefit of the method used in QuickMag is that it is much faster than the task data method (hence its name).
What does the program do?
The program works by finding the top hosts on each project with the specified model of CPU.
The number of whitelisted projects is obtained from gridcoinstats.eu and used to determine how much total magnitude is allocated to each project. This number excludes greylisted projects, even if they are still included in the results of this script.
The RAC for the top hosts is then divided by the RAC for team gridcoin and multiplied by the total magnitude for the project. This gives the magnitude awarded to each of the top hosts.
I have decided to return the list of magnitudes and not an average, because there is no easy way to handle the statistics. Depending on the popularity of the CPU model, there may only be one or two people working on a particular project. This and some other intricacies result in the mean values being misleading and that you should look for multiple hosts with similar performance.
How do I use CPU_QuickMag?
I am uploading to bash scripts. The first is:
bash UpdateDatabaseFiles.sh [Project Type]
[Project Type] can be cpu, gpu, or all
This script download the necessary host data and team data to perform the calculations in the main script. This downloads and stores around 3GB of data on the local computer if project type cpu is selected.
The primary script is:
bash CPU_QuickMag.sh [CPUid] [#hosts] [output]
[CPUid] - CPU id string e.g. 'i7-6700 ' (check CPUlist.data for more examples)
[#hosts] - number of hosts to return data for
[output] - save output to file name (optional)
This script scans the previously downloaded files and returns the magnitude of the top [#hosts] with the provided CPU model. The data is saved to the file specified in [output] or printed in the terminal if no file destination is entered.
There is an additional file:
CPUlist.data
This file contains the names of common CPU models formatted to work with CPU_QuickMag.sh
Note that spaces need to be preserved, for example 'i7-6700' will return a mix of 'i7-6700 ' and 'i7-6700K'
Example Usage
$ bash UpdateDatabaseFiles.sh cpu
Skipping gpu projects
Starting 17 downloads...
Progress: 100%
$ bash CPU_QuickMag.sh 'Ryzen 5 1600' 4
Missing Host Data: cosmology
Missing Team Data: cosmology
Project | Top 4 magnitude(s) for Ryzen 5 1600
odlk1 14.99 14.72 14.56 13.65
srbase 6.70 2.62 2.21 2.13
yafu 26.94 14.02 6.14 4.19
tngrid 36.05 4.81 1.89 1.86
vgtu 23.14 22.21 16.79 11.54
DD 9.12 6.00 3.47 2.85
numf 2.32 1.28 1.24 0.92
nfs 11.95 10.44 8.82 6.42
pogs 9.66 8.16 8.10 6.90
universe 50.51 39.73 33.07 14.83
csg 8.58 7.72 5.12 2.49
cosmology 0.00 0.00 0.00 0.00
lhc 22.89 15.76 15.61 9.07
asteroids 8.17 5.72 4.52 3.68
rosetta 12.79 12.24 7.85 7.79
yoyo 27.50 22.59 15.02 11.06
wcg 14.00 12.32 12.11 8.44
If data is missing, the code sets the associated values to zero. Also note that DrugDiscovery and Universe are not in the current superblock, but are still listed.
Where can I get this script?
Get the script on Github, and try it for yourself!
https://github.com/nexus-prime/QuickMag
The GPU version of this will be released if a couple of days.
Nice post. I have a 1700 myself . I hate that projects with limited accounts offer this much magnitude.
=======================================================================================
This post was upvoted by Steemgridcoin with the aim of promoting discussions surrounding Gridcoin and science.
This service is free. You can learn more on how to help here.
Have a nice day. :)
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Good work. One issue is hosts that dont run 24/7/365 or not at 100% load will appear to skew the results. Perhaps you could also include a total of recent results returned per CPU core, which would indicate if hosts have wildly varying duty cycles/% CPU usage?
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
First of all great work @nexusprime.
Some other area which can cause variation in the output and make @scalextrix comments interesting to take into consideration:
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Awesome, I like your scripts!
Thanks to you, I can continue being lazy instead of developing :D
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
PS: Got a little issue due to my Dutch locales:
CPU_QuickMag.sh: regel 184: printf: 2.4159481835: ongeldig getal
CPU_QuickMag.sh: regel 184: printf: 4.20158347337: ongeldig getal
CPU_QuickMag.sh: regel 184: printf: 3.05274502203: ongeldig getal
CPU_QuickMag.sh: regel 184: printf: 1.09422446442: ongeldig getal
(ongeldig getal = invalid number).
Changed line 184 to
LC_NUMERIC="en_US.UTF-8" printf " %0.2f" "${locMag[@]}" >> $StatsOut
and it works like a charm :)
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
added the change to github
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Ooh! Gonna test out in a while! Will the script work inside Linux subsystem for Windows?
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Definitely, that's where I run them.
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit
Great, I won't have to create a VM just to test your script!
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit