Godtone
Joined 17 December 2020
→Novation Launchpad Pro MK3 isomorphic keyboard code: catalogue inconsistency error that may occur |
m →zeta and optimal_edo_sequence: more data |
||
| (4 intermediate revisions by the same user not shown) | |||
| Line 9: | Line 9: | ||
* [[User:Godtone/zeta]] | * [[User:Godtone/zeta]] | ||
Whose significance is backed up by the more psychoacoustically-informed tuning metrics I've designed (<code>optimal_edo_sequence</code>s from [[#My Python 3 code]]): | Whose significance is backed up by the more psychoacoustically-informed tuning metrics I've designed (<code>optimal_edo_sequence</code>s from [[#My Python 3 code]]): | ||
* [[User:Godtone/optimal edo sequences]] | * [[User:Godtone/optimal edo sequences]] (and [[User:Godtone/strict_optimal_edo_sequences]]) | ||
...as well as by my own knowledge of tuning theory. | ...as well as by my own knowledge of tuning theory. | ||
| Line 466: | Line 466: | ||
== My Python 3 code == | == My Python 3 code == | ||
IMPORTANT NOTE: there seems to be | IMPORTANT NOTE: there seems to be bugs for subgroup mappings at the moment, pending investigation, but ideally usage of subgroups should be made far easier too: | ||
<syntaxhighlight lang="python"> | <syntaxhighlight lang="python"> | ||
>>> sg = [2, 3, 7, 11, 13, 17, 19] | >>> sg = [2, 3, 7, 11, 13, 17, 19] | ||
| Line 1,518: | Line 1,518: | ||
return result | return result | ||
# the length of the mediant path of whichever octave-revoicing gives the interval x the least length | |||
def mediant_complexity(x,revoicing_octs=7): | def mediant_complexity(x,revoicing_octs=7): | ||
mincomplexity = 2**30 | mincomplexity = 2**30 | ||
| Line 1,550: | Line 1,551: | ||
print() | print() | ||
return spaces | return spaces | ||
# there is only finitely many EDOs which provide some simplification of a set of intervals as contrasted to all-distinct | |||
def efficient_edos( n, inconsistencies=0, min_simplifications=1, edos=range(1,1000) ): | |||
if type(n)==int: | |||
n = odd_lim(n) | |||
elif type(n)==list and type(n[0])==int: | |||
n = odd_lim(1,[],n) | |||
results = [] | |||
for edo in edos: | |||
v = edo | |||
if type(v)==int: | |||
v = val( lim(max([ prime_idx(len(fact(x))-1) for x in n ])), ed(edo) ) | |||
# else v is assumed to be a mapping | |||
m = dict() | |||
for x in n: # collect mappings of intervals | |||
sedo = map_iv(v,x) | |||
if sedo in m: | |||
m[sedo].append(x) | |||
else: | |||
m[sedo] = [x] | |||
if len(inconsistent_ivs_by_val(n,v)) <= inconsistencies: | |||
if len(n) - len([ sedo for sedo in m ]) >= min_simplifications: | |||
results.append(edo) | |||
return results | |||
</syntaxhighlight> | </syntaxhighlight> | ||
| Line 1,622: | Line 1,647: | ||
'''It should be compatible with any Launchpad that has [[#Putting the Launchpad in programmer mode|programmer mode]]; it has been confirmed to work for the Launchpad X so will likely also work for a Launchpad Mini MK3.''' | '''It should be compatible with any Launchpad that has [[#Putting the Launchpad in programmer mode|programmer mode]]; it has been confirmed to work for the Launchpad X so will likely also work for a Launchpad Mini MK3.''' | ||
ALSO: This should go without saying but take care of your launchpad! If you wipe it don't expect it to be properly responsive until fully dry and even then wiping it can have risks if the liquid goes inside. Similarly, do not bang it and probably don't leave it upside down (especially if for long periods of time) in case it causes the velocity sensitivity to go weird. Treat it as an instrument. If you do all this, it should be fine to use it for its intended purpose: just don't press ''too'' hard; try not press with more velocity than the buttons actually require, if possible. (Because of my silliness (not heeding such obvious procedures) there is a possibility that I may have weared my launchpad slightly in that I think I now require more pressure for the pressure-sensitive pads. I thought it responsible to add this note about taking care of your launchpad, as we are technically using it in a nonstandard way by treating the buttons as though they were just insensitive pads that require extra velocity/pressure.) | ALSO: This should go without saying but take care of your launchpad! If you wipe it don't expect it to be properly responsive until fully dry and even then wiping it can have risks if the liquid goes inside. Similarly, do not bang it and probably don't leave it upside down (especially if for long periods of time) in case it causes the velocity sensitivity to go weird. Treat it as an instrument. If you do all this, it should be fine to use it for its intended purpose: just don't press ''too'' hard; try not press with more velocity than the buttons actually require, if possible. (Because of my silliness (not heeding such obvious procedures) there is a possibility that I may have weared my launchpad slightly in that I think I now require more pressure for the pressure-sensitive pads. I thought it responsible to add this note about taking care of your launchpad, as we are technically using it in a nonstandard way by treating the buttons as though they were just insensitive pads that require extra velocity/pressure.) | ||
| Line 1,631: | Line 1,654: | ||
=== Installation issues/troubleshooting strategies/recommendations === | === Installation issues/troubleshooting strategies/recommendations === | ||
The most potentially difficult part is that depending on what OS you are using, how you have Python installed, what version, etc. there can be complications so that running <code>pip install rtmidi</code> and <code>pip install mido</code> in a terminal does not work, or only appears to work so that there's issues when the code tries to use mido. I list potential issues below, so please read carefully for something applicable to your case if it isn't going smoothly. | The most potentially difficult part is that depending on what OS you are using, how you have Python installed, what version, etc. there can be complications so that running <code>pip install rtmidi</code> and <code>pip install mido</code> in a terminal does not work, or only appears to work so that there's issues when the code tries to use mido. I list potential issues below, so please read carefully for something applicable to your case if it isn't going smoothly. | ||
'''IMPORTANT: A strange error has been found: Python 3.14 and later versions have removed a functionality used by mido internally, so downgrading to Python 3.12 is required if nothing here works.''' | |||
'''IMPORTANT:''' Before deeming an installation of mido/rtmidi to "not be working", make sure that the issue is not just one of what MIDI ports are being autoselected; see (6.) onwards for details. | '''IMPORTANT:''' Before deeming an installation of mido/rtmidi to "not be working", make sure that the issue is not just one of what MIDI ports are being autoselected; see (6.) onwards for details. | ||