-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Update openMHA.cfg with new inversion filters #13
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Irgendetwas stimmt mit den Koeffizienten, abgesehen von der Ziel-Samplerate, nicht.
Der Gain für eine Referenz-Frequenz sollte 0 dB sein, z.B. für 1000Hz.
Das war, wenn ich mich richtig erinnere, meine Wahl bei der bestimmung von "peaklevel".
@@ -9,9 +9,9 @@ mha.fragsize = 48 | |||
mha.plugin_name = transducers | |||
|
|||
mha.transducers.calib_in.peaklevel = [111.4 111.4] | |||
mha.transducers.calib_in.fir = [[0.05715807311106352 -0.09143269871454363 0.1279991931078954 -0.1229917176472585 0.03865469459901275 0.1208478993167953 -0.8820088913999001 -0.2804647683673479 0.01220373264309236 -0.1613181711981604 0.1851746406520001 -0.1149274499260817 0.04848940622236251 0.03877744359967165 -0.0533381761233464 0.06159030633073432];[0.05715807311106352 -0.09143269871454363 0.1279991931078954 -0.1229917176472585 0.03865469459901275 0.1208478993167953 -0.8820088913999001 -0.2804647683673479 0.01220373264309236 -0.1613181711981604 0.1851746406520001 -0.1149274499260817 0.04848940622236251 0.03877744359967165 -0.0533381761233464 0.06159030633073432]] | |||
mha.transducers.calib_in.fir = [[0.38830 -51.63502 -21.61600 2.13690 -5.86821 6.76826 -3.84954 2.51246];[0.38830 -51.63502 -21.61600 2.13690 -5.86821 6.76826 -3.84954 2.51246]] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably these coefficients are for a samplerate of 44100 Hz.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes should not change the frequency response too much, however
A = [[0.05715807311106352 -0.09143269871454363 0.1279991931078954 -0.1229917176472585 0.03865469459901275 0.1208478993167953 -0.8820088913999001 -0.2804647683673479 0.01220373264309236 -0.1613181711981604 0.1851746406520001 -0.1149274499260817 0.04848940622236251 0.03877744359967165 -0.0533381761233464 0.06159030633073432]]; B = [[0.38830 -51.63502 -21.61600 2.13690 -5.86821 6.76826 -3.84954 2.51246]]; plot(20.*log10(abs(fft(A,48000)))); hold on; plot(20.*log10(abs(fft(B,48000))))
shows a huge difference in the gains due to the old and new filter coefficients.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mit geänderten 48000 schlage ich
0.0017587 0.0800005 -0.0386776 -0.0132063 0.1627805 0.0112068 -0.1299747 0.0074928
vor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Schau doch bitte mal ob du gleiche Ergebnisse bekommst für N=8, D=6. Sollte das nicht der Fall sein muss sich noch ein Fehler in meiner oder deine Berechnung befinden. Ich meine, dass ihr meine Skripts abgesegnet habt..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Die neuen Koeffizienten sehen auf jeden Fall besser aus.
Ich kann aber grad nicht nachvollziehen warum nur wegen der Samplerate der Unterschied zu den Koeffizienten vorher so groß ist.
Trotzdem ist der Unterschied zwischen diesen Koeffizienten und den vorherigen noch erheblich (>15dB).
A = [[0.05715807311106352 -0.09143269871454363 0.1279991931078954 -0.1229917176472585 0.03865469459901275 0.1208478993167953 -0.8820088913999001 -0.2804647683673479 0.01220373264309236 -0.1613181711981604 0.1851746406520001 -0.1149274499260817 0.04848940622236251 0.03877744359967165 -0.0533381761233464 0.06159030633073432]]; B = [[0.0017587 0.0800005 -0.0386776 -0.0132063 0.1627805 0.0112068 -0.1299747 0.0074928]]; plot(20.*log10(abs(fft(A,48000)))); hold on; plot(20.*log10(abs(fft(B,48000))))
Bei mit funktioniert unter Octave das Script "Inversion_mic_parameters_plot" nicht.
Es fehlt der Pfad zu "tools".
Füge ich ihn manuell hinzu bekomem ich folgenden Fehler:
error: vf_sig(1,,,_): but vf_sig has size 0x0
error: called from
fftR at line 35 column 8
average_imp at line 35 column 8
Calculation_inversion_mic at line 18 column 15
Inversion_mic_parameter_plots at line 20 column 39
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Der Fehler lag daran, dass die Pfade fest für Windowssysteme kodiert waren.
Ich habe die Anpassungen für eine Betriebssystemunabhängige Lösung gemacht und gepusht.
Trotzdem kommen bei mir andere Werte raus.
Ich habe die .mat files aus der Owncloud-Freigabe geladen
Kannst du mal schauen ob, wenn du die Dateien (sowohl Skripte als auch die Impulsantworten) frisch runterlädst noch dieselben Ergebnisse bekommst?
Bei mir kommt mit "Inversion_mic_parameters_plot" folgendes raus:
mha.transducers.calib_out.peaklevel = [92.8 92.8] | ||
mha.transducers.calib_out.fir = [[-0.0008493245925390666 0.212079412419309 -0.2154042301549152 -0.3025302897591955 0.199775619155252 -0.1870229266228919 -0.7938470989741924 0.8603675948896129 0.478909142449632 -0.6085003614478869 0.07361724294587288 -0.2227288472200418 0.5368590771510556 0.09111033102709504 -0.480841985504344 0.4390128813205694 0.1246445045880798 0.1269349882268854 -0.04198884835603302 -0.2353992092127431 0.2510197443337887 0.0874549322159773 -0.02924594207986645 0.03500546824173258 0.02306546293053465 0.02935658669200722 -0.04983617327855945 0.01127518725520369 -0.03557732411817455 -0.08252133997595766 0.09626162395832474 -0.03965187059451832 -0.02978787895722923 -0.02032215684247022 -0.07226667524292203 0.1197853714014079 -0.07509868745444499 -0.06716864521583707 0.01498418308780167 -0.0128555683058882 0.005643946502094473 -0.05468486125562624 -0.03084551017547309 0.01713430717627588 -0.04031926622896171 -0.0001434979760821464 -0.02137092800354339 -0.02993680876827081];[ -0.0008493245925390666 0.212079412419309 -0.2154042301549152 -0.3025302897591955 0.199775619155252 -0.1870229266228919 -0.7938470989741924 0.8603675948896129 0.478909142449632 -0.6085003614478869 0.07361724294587288 -0.2227288472200418 0.5368590771510556 0.09111033102709504 -0.480841985504344 0.4390128813205694 0.1246445045880798 0.1269349882268854 -0.04198884835603302 -0.2353992092127431 0.2510197443337887 0.0874549322159773 -0.02924594207986645 0.03500546824173258 0.02306546293053465 0.02935658669200722 -0.04983617327855945 0.01127518725520369 -0.03557732411817455 -0.08252133997595766 0.09626162395832474 -0.03965187059451832 -0.02978787895722923 -0.02032215684247022 -0.07226667524292203 0.1197853714014079 -0.07509868745444499 -0.06716864521583707 0.01498418308780167 -0.0128555683058882 0.005643946502094473 -0.05468486125562624 -0.03084551017547309 0.01713430717627588 -0.04031926622896171 -0.0001434979760821464 -0.02137092800354339 -0.02993680876827081]] | ||
mha.transducers.calib_out.fir = [[-0.0051100 0.0058418 -0.0029015 -0.0075854 0.0054159 -0.0065281 -0.0138712 0.0280986 -0.0101577 -0.0018500 -0.0015728 0.0011131 0.0135029 -0.0179051 0.0148077 -0.0026030];[-0.0051100 0.0058418 -0.0029015 -0.0075854 0.0054159 -0.0065281 -0.0138712 0.0280986 -0.0101577 -0.0018500 -0.0015728 0.0011131 0.0135029 -0.0179051 0.0148077 -0.0026030]] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
... and these as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-0.00248576 0.00427128 -0.00354440 -0.00515774 0.00339607
-0.00750198 -0.00889310 0.02055027 -0.00295105 -0.00612312 -0.00140463 0.00479821 0.00721842 -0.01088499 0.00897386 0.00082907
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hier ist N=16 und D=8. Auch berechnet den gepushten Skripten. Ich werde die Diskussion und Bilder überarbeiten sobald wir wissen, ob die Filterkoeffizienten passen.
The inversion filters figured in Inversionfilters are set in the config.