Array --> Delete Duplicates?
- oli_lab
- Member
- Posts: 1286
- Location: Brittany, France
- Contact:
can be done with a script
or
a user module
what do you want to use it for ?
or
a user module
what do you want to use it for ?
http://oli-lab.org
Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces
follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social
Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces
follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social
-
lytz1
- Member
- Posts: 123
I need it to delete duplicate numbers that get queued to an array which indices
shouldn't receive the same number more than once. So that every index has a unique number.
Because a semi random setup is feeding the matrix, duplicate numbers happen which leads to subpar output. That's why I am asking.
shouldn't receive the same number more than once. So that every index has a unique number.
Because a semi random setup is feeding the matrix, duplicate numbers happen which leads to subpar output. That's why I am asking.
-
23fx23
- Member
- Posts: 2545
maybe rather than processing the array you can check if incoming value is in array , and let it pass to be queued only if its not.
ie use A=B, to check if incoming value A match array (B). use a sum array, if sum>0 then that mean the value is already in array, so can ie stop the floa before the queue.
ie use A=B, to check if incoming value A match array (B). use a sum array, if sum>0 then that mean the value is already in array, so can ie stop the floa before the queue.
- x.iso
- Member
- Posts: 565
- Location: RU, Saint-Petersburg
- Contact:
There's also Oli_lab's module Random bag in add-ons, which can help with that kind of 'random-no-repeat' stream.
join Hollyhock Usine Discord server: https://discord.gg/EdJarnE
- oli_lab
- Member
- Posts: 1286
- Location: Brittany, France
- Contact:
try the random bag V2 user module from the oli_lab addon
it shuffle a suite of numbers at random with no duplicate.
it shuffle a suite of numbers at random with no duplicate.
http://oli-lab.org
Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces
follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social
Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces
follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social
- oli_lab
- Member
- Posts: 1286
- Location: Brittany, France
- Contact:
Hi !
I did this module.
http://www.sensomusic.org/forums/uploads.php?file=Oli_Lab_arrayNoDuplicate.zip
before I start the mac mini, it's win64 only...
with few fun options :
mode :
on change = when a new array is received, each value is tested against the values already present inside the memory
button = when a button is receivedon the "enter" input, each value is tested against the values already present inside the memory
max size : set the max size of the output array, if this value is less than the size of the output array, the array is truncated.
enjoy !
I did this module.
http://www.sensomusic.org/forums/uploads.php?file=Oli_Lab_arrayNoDuplicate.zip
before I start the mac mini, it's win64 only...
with few fun options :
mode :
on change = when a new array is received, each value is tested against the values already present inside the memory
button = when a button is receivedon the "enter" input, each value is tested against the values already present inside the memory
max size : set the max size of the output array, if this value is less than the size of the output array, the array is truncated.
enjoy !
http://oli-lab.org
Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces
follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social
Win11 Ryzen9/32GB RAM - RME MADIFACE - SSL alpha link 4-16 - OSC capable interfaces
follow OLI_LAB adventures on Mastodon
@olivar_premier@mastodon.social
