Elk-herd 3.3 Release

@mzero Thanks for the update, I have been using since Digitakt 1 and it is fantastic. 3.3 Release works well for me with Digitakt 1. However, i am getting the same message as Revshark when trying to fetch projects on Digitakt 2 I can see samples ok.

Computer OS is Windows 10 Home - Could this be the issue?
Version 2009
OS Build 19045.5854

Have tried Chrome Version 137.0.7151.57 (Official Build) (64-bit)
Have also tried Edge and Firefox

Digitakt is connected over USB direct to computer.

Digitakt firmware is 1.10

Many Thanks.

2 Likes

If i can add a data point, I got this same “Project doesnt have all the patterns” error from an up-to-date Win 11 pro machine last night on Chrome, DT2 running 1.10 (Id been waiting to update until after posting a set); Elk-herd worked fine on the same project, same DT2 OS on MacOS (up-to-date version). Happy to share any logs or the like if it’s useful.

@Morph it might be worth trying what you were looking to do on a different machine if you have one nearby…

1 Like

Thanks @Humanprogram. Appreciate the reply, yeah have tried with another Windows 10 machine with no joy. Have yet to try Windows 11, will try this later today. Will also have a look at if Windows can let larger midi messages through, based on the post from @mzero about large sysex files.

You just saved me so much time and energy, being able to import entire sample packs with the folder structure intact to the Rytm!

This piece of software is amazing!!! THANK YOU SO MUCH! :raised_hands: :dizzy: :clap::clap::clap:

2 Likes

There’s no words enough to thank you for this. :heart:

3 Likes

@Humanprogram @mzero Have this working on a Windows 11 machine.

When elkherd says “These samples are the same” presumably it’s saying that based on identical hashes ?

1 Like

It means that the sames have identical sizes and hashes - which is the same criteria that the unit itself uses to identify unique samples.

It is natural to have concern that two audio samples could be different but hash the same. While theoretically possible, the chances of such a collision are very slim. The hash in Elektron machines is only 32-bits, which is less than ideal - but coupled with the size makes collisions unlikely to be observed in any of our lifetimes.

9 Likes

What kind of math is that?

Interesting: Given exactly the same prompt, ChatGPT also references the birthday paradox, but concludes

about 1 in 2145 chance.

Interested to hear what @mzero has to say, could be both AIs are wildly off.

As I recall, algorithms that use Hashes (other than for encryption purposes) are used to speed up searches across a set of source by keeping a table of hash values that pointed to a list (typically a linked list) of sources (files) that produced that hash value.

If you have more than one element in the list for a given hash value, you then searched linearly through the list and compare the underlying sources (files). This is fast since, presumably, there are few hash collisions and only a small number of elements in the linked list.

Until Digitakt, I’ve never actually heard of a system that took the hash value to be the definitive determinant that “this is the correct source”.

Here’s a reasonable overview, with a good diagram of hash collisions:

Interested to hear what @mzero has to say

Well, the first thing I’m going to say is don’t try to do math with “AI”. Large Language Models are trained to produce “reasonable textual responses”, not to compute values or deliver facts. One of those answers may be right… so why both with the AI if you want the actual answer, since you’ll have to check with and actual source info about the subject to be sure?


Now, considering only the 32-bit hash, the probability of a collision in 2000 samples is:

h = 2 ^ 32        -- number of possible hashes
k = 2000          -- number of elements
u = h! / (h -k)!  -- number of ways to have k unique hashes
a = h ^ k         -- number of ways to have k hashes (unique or not)
q = u / a         -- probability of having all unique hashes in a random group of k elements
p = 1 - q         -- probability of having a collision in a random group of k elements

These numbers are big (it’s those factorials), and direct calculation won’t generally be possible. So, we use approximations. The following is good enough for our purposes:

p ≈ 1 - e ^ -( k^2 / 2h )   -- useful if k << h, which it is
p ≈ 0.000466 ≈ 1 in 2148

Diversion: Google’s AI is bullshitting its way through, and its conclusion is very misleading. ChatGPT has gotten this one correct, but don’t expect less bullshit from it in general just because it got this one right.


Now - what does this mean in practice. Let’s spell it out:

If you load a Digitakt with 2000 random samples, all the exact same length, then you have about a 1 in 2000 chance that there is a hash collision between two samples.

-or-

You have to make 1000 collections of 2000 random samples, all the exact same length, before you have about a 50% chance of seeing a collision in one of those sets.

Okay, I get that a casual eye, this looks like the realm of possibility. I admit, that as an engineer, I would have done this calc, and then increased the hash size used by the system. (For example, just increasing to 40 bits makes p ≈ 1 in 550,000.)

But remember that we are only talking about samples of exactly the same size. I did a search over my entire collection of samples (though I’m sure some of you have larger ones) - here’s the top ten repeated sample sizes:

 n | size of sample
73   133760
64   209024
64   150656
46   2648192
32   530048
32   464000
32   331904
30   2119808
16   79424
16   767384

Let’s take 73 as the value of k: The chance that these samples have a collision is:

p ≈ 1 - e ^ -( 73^2 / 2*2^32 )
p ≈ 0.00000062038 or 1 in 1.6 million

I think we’re in generally safe territory…


Hashes are used for many things beyond just hash tables. Pretty much every cryptographic protocol (including https: that we are using right now) has hashes involved.

Hash tables worry about collisions because h is so small: the size of the table, typically at most 1000s.

In most other uses, h is very big: 2^64 or 2^128 is common. In these cases, collisions in any reasonably sized set are virtually non-existent.

How non-existant? If you assigned a 128 bit hash to every atom on earth (1.3 * 10^50 of them) - you still only have a chance of collision 1 in 60 million million times! If you make that assignment anew every second, it would still take you 900k years before you had a 50% of collision.

Given these numbers, it is quite common to use a large hash to be a definitive determinant of a identity. Every digitally signed document and certificate relies on this. Many digital asset systems (like collections of images, 3D models, etc.) also use hashes as equivalent to identity.


Sorry for the long explanation… in a prior time, I was a cryptographic researcher at Google working on systems extensively using hashes!

Meanwhile, I had been focusing on rehearsing for a gig that was just last Sunday, and now I can get back to elk-herd… which might have a bug or two to be squashed!

17 Likes

There is a popular collection of single cycle waceforms with over 2000 samples and people reported to have problems with that collection on their digitakt… it turned out that there were duplicate hash codes assigned.

2 Likes

No apology needed from here … thanks for the explanation … though I’m technically a maths graduate, in practice a lot of it is forgotten, and cryptography etc was never my thing anyway.

:+1:

1 Like

Heads up: I know there is a new DT II OS release… I expect the technical info I need from Elektron in the next few days… and then it might take me a week or so to get there. (It’s Pride week here in SF, so somewhat busy! :rainbow_flag: :grin:) But rest assured, elk-herd will be updated a quick as I can.

30 Likes

What a gentleman. This is really going above and beyond the call of duty when you’re giving progress reports on a free service which is no doubt more inconvenient for you than it is not.

Very cool guy right here.

11 Likes

U r awesome. Happy pride!

5 Likes

I don’t have a DTII but yet so touched by your consideration for the users of your program

3 Likes

“I think it’s just awesome how you handle this and always respond so up-to-date.

Rarely have I experienced such dedication. Thank you!

That alone deserves a beer :wink:

4 Likes

Not quite as awesome as @mzero doing all this for free, but also notable, is that Elektron appear to be supporting his efforts.

5 Likes