Topic: Pianoteq Benchmark Feature Suggestion

Hello,
I've been wondering if it would be a good idea for Pianoteq to have a built in benchmark function. The purpose would be to test the system it's running on to see if it's good enough to handle Pianoteq properly.
The benchmark would be available in the trial versions, and it should pretty much throw everything it's got at the CPU, record the load percentages and perhaps have the user listen to it at a given sample rate to monitor for pops in the sound.

The reason I thought of this is because I'm currently looking for a small dedicated computer to run Pianoteq on. The Intel NUCs are prime contenders, and this model (DN2820FYKH) in particular is really affordable and has a on-board sound card (mini jack output). I'm not certain about the CPU though. I believe this scenario will be increasingly common for people who want a software piano, now that PCs are becoming smaller and faster.

Using a benchmark I could simply ask someone who owns a system I'm interested in to run the benchmark, rather than buying a system in the blind hoping for the best. One must also take into account that as the modelling in Pianoteq becomes more advanced, faster CPUs might be required for future versions so there should be some headroom.

What do you think, good/bad idea? Feasible?


An OT note on people interested in NUC systems, be aware of the many issues regarding sound output, headless use, and more:
Intel NUC support forum

Re: Pianoteq Benchmark Feature Suggestion

That would be amazing! And to bring it to perfection, a platform, where you can upload your results and share it with others, so everyone can compare and see what best fits his needs.
Concerning those Intel NUCs, they are very interesting pieces of technology! jarosujo has set up a headless machine with the DC3217BY (Ivy Bridge processor generation): http://www.forum-pianoteq.com/viewtopic.php?pid=930717 This one is around 150€. It does not have an integrated 3.5mm phone connector output, but I wouldn’t rely on that output anyway. A USB sound card for ~50-100€ (or maybe even less?) pretty certainly does a better job.
But to come back to topic, such a benchmarking system/platform would be a great thing!

Re: Pianoteq Benchmark Feature Suggestion

Well, you didn't include the cost of this feature.

If it is free, I (and everyone else says ... great !).

Do you still want it if it increases the cost of the product $50 ?

Everything has a cost.

Re: Pianoteq Benchmark Feature Suggestion

Thanks for pointing that out!
I don’t know, whether it indeed would be that expensive – the developers would probably know.
But I suppose, the aim of this thread is to get to know, whether others users would at all be interested in such a feature.

Re: Pianoteq Benchmark Feature Suggestion

Perhaps instead of the developer writing the benchmark, you can script it yourself -- sorta like how games w/o built-in benchmarks use FRAPS.

What you'd need is a launcher utility to play a MIDI file + measure the exact cpu usage during the time.  Get the peak usage, get the average usage.

Would be best to be able to launch Pianoteq also with command line parameters while slowing scaling up the polyphony.  (... checking command line parameters now ...)  OK -- it is available.  There is an option to save preferences in specific files so you make 32/64/128/256 files and run the test multiple times using different configs.

Then you'd generate a score that's based on max polyphony.  If you can hit 256 with 10% cpu usage, we'd give your system a score of 256 * 10 of 2560.

For Linux, it would be a breeze to script.  No idea about Windows.

Last edited by Mossy (03-03-2014 01:40)

Re: Pianoteq Benchmark Feature Suggestion

Here's a simple script I made for Linux to produce a benchmark.  Those of you with Windows scripting chops can figure out how to do this under Windows.

#!/usr/bin/perl

# copy this script to your PTQ root directory
# (e.g. below the AMD64/i386 directories)

# File to use:
$FILE = "He_s a Pirate.mid";

# which version to use?
$VER = "./amd64/Pianoteq\\ 4";
#$VER = "./i386/Pianoteq\\ 4";

# start time
$START = time;

# run
system("$VER --play-and-quit --headless --no-audio-prefs --preset \"U4 Daily Practice\" --midi \"$FILE\" --wav /tmp/_delete_me.tmp");

# end time
$END = time;

# remove temp file
unlink("/tmp/_delete_me.tmp");

# calculate score
# since we like higher numbers, we will invert
$TIME = $END - $START;
$SCORE = int(10000/$TIME);

print "The PTQ score for this system is $SCORE\n";

I did not use the idea of monitoring idle time.  I thought about that for a while and realized under Intel CPUs with hyperthreading, you don't know whether it's a real core that's available or a virtual core.  However, the output to wave option does not run using "playing time" so it probably uses as much resources as possible -- hence you can take NUMBER/time as a simple score.

Here are numbers for some machines I have access to.   EDIT: now includes a few desktop machines.  In the 1-core VM tests, PTQ does not seem to comprehend virtualized CPUs and runs even slower when more CPUs are allocated.


i5 M430 (Nehalem-C) @ 2.2ghz 64-bit: 500
i5 2500 (Sandy Bridge 1-core VM) 3.3ghz 64-bit: 476
i5 M430 (Nehalem-C) @ 2.2ghz 32-bit: 476
AMD FX-8120 (Bulldozer) 3.1ghz 64-bit: 434
i3 3227U (Ivy Bridge) @ 1.9ghz 32-bit: 416
AMD Phenom II (Thuban 1-core VM) 3.2ghz 64-bit: 370
AMD Phenom II (Deneb 1-core VM) 3.0ghz 64-bit: 322
i5 M430 (Nehalem-C) @ 1.2ghz 64-bit: 285
i5 M430 (Nehalem-C) @ 1.2ghz 32-bit: 256
Pentium T2300 (Core 2) @ 1.5ghz 32-bit: 217
i3 3227U (Ivy Bridge) @ 800mhz 32-bit: 192
Pentium T2300 (Core 2) @ 800mhz 32-bit: 133
Intel Atom N450 (Pineview) @ 1.66ghz 32-bit: 94

The 250ish threshold for PTQ4 the rough requirement for 200+ polyphony.  The T2300 (~200 score) garbles notes under more complex playback.

---

Oh, and here's a score you guys will be really interested in:

Intel Atom C2750 @ 2.4ghz 64-bit: 333
Intel Atom C2750 @ 1.2ghz 64-bit: 178

What's this?  This is the 8-core server version of the latest Intel Atom CPU.  The only difference is this has 8-cores (using it at work to run firewall VMs) while consumer versions have 2/4 cores.  (Pianoteq only uses 2 cores maximum from monitoring cpu usage.)

So you if want an ultra low power CPU, a Bay Trail NUC/Chromebook would draw 7.5W under full load.  This is a SoC number ... non-SoC CPUs add another 10W-15W because the northbridge/southbridge also draws power.  (See a recent Anandtech review where 17W non-SoC laptops draw 35Wish compared to AMD Kabini SoC laptop drawing UNDER power rating.)  The 333 score puts it solidly above the ~250 requirement ... hence I'd wait to see when the ASUS Baytrail Chromebooks are coming out.  They'll supposedly be available for $200-$250 (USD, no idea about Europe pricing) and at that kind of power usage, you can leave it on all the time -- sleep or no sleep.

Last edited by Mossy (04-03-2014 13:22)

Re: Pianoteq Benchmark Feature Suggestion

http://www.cpubenchmark.net/cpu_list.php

Sort it by passmark CPU (second column).
From my experience, 2000+ should be fine for PT even for high polyphony usage.
But still I would "try before buy"  :-)

Re: Pianoteq Benchmark Feature Suggestion

Gerhard wrote:

That would be amazing! And to bring it to perfection, a platform, where you can upload your results and share it with others, so everyone can compare and see what best fits his needs.
Concerning those Intel NUCs, they are very interesting pieces of technology! jarosujo has set up a headless machine with the DC3217BY (Ivy Bridge processor generation): http://www.forum-pianoteq.com/viewtopic.php?pid=930717 This one is around 150€. It does not have an integrated 3.5mm phone connector output, but I wouldn’t rely on that output anyway. A USB sound card for ~50-100€ (or maybe even less?) pretty certainly does a better job.
But to come back to topic, such a benchmarking system/platform would be a great thing!

Very good idea of creating a database of benchmark scores! Pianoteq should then simply offer to upload the result of the benchmark to their servers after completion. A simple list of CPU's and average score on some page somewhere on the site would be sufficient. Pianoteq seems to me like a well-written and well-optimized application, and most modern CPU's can handle it with ease. However, these low-power systems will make this sort of information valueable again, as some balance right on the edge!

Indeed, jarosujo's review was very helpful! I believe that price was for a second hand unit, all in all you'd probably end up spending more. I can see the use for a good external soundcard if you're into recording or studio work, but for a lot of people modern on-board sound is good enough. It would be for me! It would also help keep costs down. I'm running Pianoteq on two different Realtek on-board sound interfaces now, the latency is low, sound quality good, and no interference. I'm not an audiophile though, and don't see the need for 24 bit 192 kHz etc., especially not for daily practice.
I'm hoping this will make it to market, would be pretty great to strap onto the VPC1 for example...

ddascher wrote:

Well, you didn't include the cost of this feature.

If it is free, I (and everyone else says ... great !).

Do you still want it if it increases the cost of the product $50 ?

Everything has a cost.

You're right, everything has a cost. However I don't think it would increase the price of the product by $50. Most of the functionality you'd need is already built into Pianoteq, Modartt would simply need to arrange some specific benchmark routine of existing functions. I would wager a simple alpha version to iterate on could be whipped up in an afternoon. For all we know they already have this in non-production code!
There's a performance index in the options for example. I didn't find any documentation on it, but it could surely be utilised.
Furthermore I don't think it's a good attitude to keep from suggesting features fearing the implicated cost, and encourage others to hold back. Modartt don't have to listen to us, but they might if the things we suggest make sense. Let's leave the business decisions up to them. Keeping the product minimal and hacker friendly seems important to them, I don't think we need to fear feature creep and bloat either.

Mossy wrote:

Perhaps instead of the developer writing the benchmark, you can script it yourself -- sorta like how games w/o built-in benchmarks use FRAPS.

...snip...

Great work Mossy! I had no idea Pianoteq had a command line interface like that. I don't have the CLI skills to whip up the same script for Windows, but I did give the command a spin, very interesting.

I'm not sure how well it reflects actual live performance though? Perhaps it's the same thing, I don't know. Running it at different sample rates would also be important I think, but maybe that's possible by loading different --prefs files. And of course polyphony as you mentioned.
It's a bit curious that Pianoteq would garble notes when just producing a wav file, I thought it would take all the time it needed and to produce perfect output on any system. Or perhaps you meant that it does that when playing the midi in real-time on the low-scoring systems?

You sure have a lot of computers! Very useful benchmarks, especially the last ones. Thanks for taking the time to investigate this! The CPU world is pretty confusing, and I'm certainly no expert. Only getting interested now because I want to play the piano with the minimum amount of hassle, power consumption and fan noise.

jarosujo wrote:

http://www.cpubenchmark.net/cpu_list.php

Sort it by passmark CPU (second column).
From my experience, 2000+ should be fine for PT even for high polyphony usage.
But still I would "try before buy"  :-)

Yes I'm looking at general benchmarks of that sort, but like you say, it would be useful to really know what you're getting. A Pianoteq specific benchmark would be nice. Thanks for the tip though and for your contributions to the community!


Although this kind of (crude) benchmarking is currently possible, my suggestion still stands. I think it would be very convenient to have a benchmark like this built into Pianoteq, preferably playing live so the user can monitor the sound for defects, together with a database of user-submitted scores. My humble opinion!

Re: Pianoteq Benchmark Feature Suggestion

There are fanless cases available for those Intel NUC boards as well: e.g. Streacom ST-NC1S-GK (~85€) or Akasa Newton V (~50€). The ~150€ is for the kit (DC3217BY), thus the board with a plastic case (with fan). The board is available without case as well, but its not really cheaper. What you still need is RAM and SSD, for about 100€. But this would be enough for a headless PC (if I didn’t forget anything), summing up to ~250€ for a “fan-ny” machine. But as jarosujo reported, the fan doesn’t seem to be loud at all, at least not when just playing “moderately” …

Concerning our actual topic, the benchmarking feature: Thanks Mossy for writing such a script – ideally Modartt would include such in the program, so everyone would use the same benchmarking thing.
General CPU benchmarks are definitely useful to give you an overall clue. But there is not a single speed value of one CPU, but one task my be faster on one CPU and another task on another CPU. Therefore a Pianoteq specific benchmark value would still be interesting – and even more when you are about to buy a PC for Pianoteq only.

Re: Pianoteq Benchmark Feature Suggestion

archikeys wrote:

It's a bit curious that Pianoteq would garble notes when just producing a wav file, I thought it would take all the time it needed and to produce perfect output on any system. Or perhaps you meant that it does that when playing the midi in real-time on the low-scoring systems?

You sure have a lot of computers! Very useful benchmarks, especially the last ones. Thanks for taking the time to investigate this! The CPU world is pretty confusing, and I'm certainly no expert. Only getting interested now because I want to play the piano with the minimum amount of hassle, power consumption and fan noise.

Garbled notes when playing realtime.

I originally thought of using different prefs before examining the possible command line options.  If PTQ generated in playback time, we would have to use different preferences/ polyphony in order to measure amount of free CPU available for different scenarios.  But because PTQ uses all the CPU power it can to generate a WAV as quick as possible (different time needed for different computers), the time spent on a complex MIDI is a direct inverse of the CPU power available to run PTQ.

This is my guess on how to run do the above benchmark under Windows by hand:

"Pianoteq 4.exe" --play-and-quit --headless --no-audio-prefs --preset "U4 Daily Practice" --midi "He_s a Pirate.mid" --wav C:\_tmp_delete_me.wav

Use a stopwatch (or smartphone stopwatch wapp) to time how long it takes to run.  Then calculate:

SCORE = 10000 / (time to run)

In order to get a "big number is better" benchmark.

Last edited by Mossy (04-03-2014 01:21)

Re: Pianoteq Benchmark Feature Suggestion

I remember this virtual piano shoot-out:
http://www.vpiano.net/pianosshootout1.htm

Isn't it easier to down the sustain peddle set all the parameters to their maximum (Options/ Perf/sample rate/polyphony) then thunder away at all the keys?

Re: Pianoteq Benchmark Feature Suggestion

DonSmith wrote:

Isn't it easier to down the sustain peddle set all the parameters to their maximum (Options/ Perf/sample rate/polyphony) then thunder away at all the keys?

That is a good enough test - on a computer you already own. What I'm proposing would help when buying new equipment.

Re: Pianoteq Benchmark Feature Suggestion

I re-ran the above benchmark for PT5 on the Linux hardware I have access to.

LINUX 64-BIT, Fedora 19/20

PT4.5 PT5.0 MODEL         ARCHITECTURE SPEED   WATTS
----- ----- ------------- ------------ ------- -----
  368   254 Celeron 2995U Haswell      1400       15
  227   149 Celeron 2995U Haswell       800       15

  601   479 i5 3450       Ivy Bridge   3100       77
  580   359 i3 3227U      Ivy Bridge   1900       17
 ~350     ? Celeron 1037U Ivy Bridge   1800       17
  292   171 i3 3227U      Ivy Bridge    800       17

  546   425 i5 430M       Nehalem-C    2250       35
  283   238 i5 430M       Nehalem-C    1200       35

  425   404 AMD FX-8120   Bulldozer    3400      125
  234   172 AMD FX-8120   Bulldozer    1400      125
  377   336 AMD X2-250    Regor        3000       65
  165   111 AMD X2-250    Regor         800       65

  381   335 Atom C2750    Silvermont   2400       20 SoC
  179   171 Atom C2750    Silvermont   1200       20 SoC
  108    67 Atom N450     Pineview     1650        6 SoC

  189   161 Pentium T2310 Core 2       1400       35
  152   105 Pentium T2310 Core 2        800       35

PT5 does take more CPU power compared to PT4.5 -- anywhere from 5% more to 60% more depending on the CPU architecture.

I'm using my 4 year old laptop (i5 430M underclocked to 1.2ghz) as a dedicated Pianoteq computer.  The 238 PT5 score seems good enough for 96Hz/48Hz + unlimited polyphony.

The ~350 for the 1037U is an estimated score as I no longer have access to it.

Update: Avoton Server available again.

Last edited by Mossy (02-07-2014 03:19)