Search
Search titles only
By:
Search titles only
By:
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Forums
New posts
All threads
Latest threads
New posts
Trending threads
Trending
Search forums
What's new
New posts
New ads
New profile posts
Latest activity
Free Ads
Latest reviews
Search ads
Members
Current visitors
New profile posts
Search profile posts
Contact us
Latest ads
Ad icon
Video Content Creator
pramukag
Updated:
Sunday at 6:10 AM
Ad icon
QA Engineer Intern
pramukag
Updated:
Sunday at 6:07 AM
Ad icon
Sell your Land, House on idamata.lk for FREE
sajith.xp.pk
Updated:
Thursday at 9:03 AM
Handmade Character Soft Toys
anil1961
Updated:
Jun 23, 2026
Bodim.lk out now !
Manoj Suranga Bandara
Updated:
Jun 21, 2026
Electronics
Vehicles
Property
Search
Reply to thread
Forums
Computers & Internet
Problems and Troubleshooting
MATLAB danna un warellaa
Get the App
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
<blockquote data-quote="djlaki" data-source="post: 16155715" data-attributes="member: 7984"><p><strong><strong>yaluwane ... </strong></strong></p><p><strong><strong></strong></strong></p><p><strong><strong>mama voice recognition walata matlab haraha podi project ekak baawa eke 0-9 wenakam sinhalen kiwwama no eka display karanna thama hadala thiyenne ... mata prashnayakata thiyenne dan mama monawa hari wena wachanayak kiwwath eka meke identify karanne no ekak widihata.... example kanawa kiwwoth eka pennanda baha but number ekak display karala pennanawa ... meka nathi kara ganne kohomada ? </strong></strong></p><p><strong><strong></strong></strong></p><p><strong><strong></strong></strong></p><p><strong><strong>code eka mama pahalin danawa sup ekak deepalla poddak meka <img src="/styles/default/xenforo/smilies/default/confused.gif" class="smilie" loading="lazy" alt=":confused:" title="Confused :confused:" data-shortname=":confused:" /><img src="/styles/default/xenforo/smilies/default/confused.gif" class="smilie" loading="lazy" alt=":confused:" title="Confused :confused:" data-shortname=":confused:" /><img src="/styles/default/xenforo/smilies/default/confused.gif" class="smilie" loading="lazy" alt=":confused:" title="Confused :confused:" data-shortname=":confused:" /><img src="/styles/default/xenforo/smilies/default/confused.gif" class="smilie" loading="lazy" alt=":confused:" title="Confused :confused:" data-shortname=":confused:" /></strong></strong></p><p><strong><strong></strong></strong></p><p><strong><strong>code :- </strong></strong></p><p><strong><strong></strong></strong></p><p><strong><strong>if true</strong></strong></p><p><strong><strong>clc;</strong></strong></p><p><strong><strong>clear all;</strong></strong></p><p><strong><strong>load('voicetrainfinal.mat');</strong></strong></p><p><strong><strong>Fs=8000;</strong></strong></p><p><strong><strong>for l=1:20</strong></strong></p><p><strong><strong>clear y1 y2 y3;</strong></strong></p><p><strong><strong>display('Press ENTER to record your voice !');</strong></strong></p><p><strong><strong>pause();</strong></strong></p><p><strong><strong>x=wavrecord(Fs,Fs);</strong></strong></p><p><strong><strong>t=0.04;</strong></strong></p><p><strong><strong>j=1;</strong></strong></p><p><strong><strong>for i=1:8000</strong></strong></p><p><strong><strong> if(abs(x(i))>t)</strong></strong></p><p><strong><strong> y1(j)=x(i);</strong></strong></p><p><strong><strong> j=j+1;</strong></strong></p><p><strong><strong> end</strong></strong></p><p><strong><strong>end</strong></strong></p><p><strong><strong>y2=y1/(max(abs(y1)));</strong></strong></p><p><strong><strong>y3=[y2,zeros(1,3120-length(y2))];</strong></strong></p><p><strong><strong>y=filter([1 -0.9],1,y3'); % high pass filter to boost the high frequency components</strong></strong></p><p><strong><strong>%%frame blocking</strong></strong></p><p><strong><strong></strong></strong></p><p><strong><strong>blocklen=240;%30ms block</strong></strong></p><p><strong><strong>overlap=80;</strong></strong></p><p><strong><strong>block(1,: )=y(1:240);</strong></strong></p><p><strong><strong>for i=1:18</strong></strong></p><p><strong><strong> block(i+1,: )=y(i*160: (i*160+blocklen-1));</strong></strong></p><p><strong><strong>end</strong></strong></p><p><strong><strong>w=hamming(blocklen);</strong></strong></p><p><strong><strong>for i=1:19</strong></strong></p><p><strong><strong> a=xcorr((block(i,: ).*w'),12); % finding auto correlation from lag -12 to 12</strong></strong></p><p><strong><strong> for j=1:12</strong></strong></p><p><strong><strong> auto(j,: )=fliplr(a(j+1:j+12)); % forming autocorrelation matrix from lag 0 to 11</strong></strong></p><p><strong><strong> end</strong></strong></p><p><strong><strong> z=fliplr(a(1:12)); % forming a column matrix of autocorrelations for lags 1 to 12</strong></strong></p><p><strong><strong> alpha=pinv(auto)*z';</strong></strong></p><p><strong><strong> lpc<img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite1" alt=":-)" title="Smile :-)" loading="lazy" data-shortname=":-)" />,i)=alpha;</strong></strong></p><p><strong><strong>end</strong></strong></p><p><strong><strong>wavplay(x,Fs);</strong></strong></p><p><strong><strong>X1=reshape(lpc,1,228);</strong></strong></p><p><strong><strong>a1=sigmoid(Theta1*[1;X1']);</strong></strong></p><p><strong><strong> h=sigmoid(Theta2*[1;a1]);</strong></strong></p><p><strong><strong> m=max(h);</strong></strong></p><p><strong><strong> p1=find(h==m);</strong></strong></p><p><strong><strong> if(p1==10)</strong></strong></p><p><strong><strong> P=0</strong></strong></p><p><strong><strong> else</strong></strong></p><p><strong><strong> P=p1</strong></strong></p><p><strong><strong> end</strong></strong></p><p><strong><strong>end</strong></strong></p></blockquote><p></p>
[QUOTE="djlaki, post: 16155715, member: 7984"] [B][B]yaluwane ... mama voice recognition walata matlab haraha podi project ekak baawa eke 0-9 wenakam sinhalen kiwwama no eka display karanna thama hadala thiyenne ... mata prashnayakata thiyenne dan mama monawa hari wena wachanayak kiwwath eka meke identify karanne no ekak widihata.... example kanawa kiwwoth eka pennanda baha but number ekak display karala pennanawa ... meka nathi kara ganne kohomada ? code eka mama pahalin danawa sup ekak deepalla poddak meka :confused::confused::confused::confused: code :- if true clc; clear all; load('voicetrainfinal.mat'); Fs=8000; for l=1:20 clear y1 y2 y3; display('Press ENTER to record your voice !'); pause(); x=wavrecord(Fs,Fs); t=0.04; j=1; for i=1:8000 if(abs(x(i))>t) y1(j)=x(i); j=j+1; end end y2=y1/(max(abs(y1))); y3=[y2,zeros(1,3120-length(y2))]; y=filter([1 -0.9],1,y3'); % high pass filter to boost the high frequency components %%frame blocking blocklen=240;%30ms block overlap=80; block(1,: )=y(1:240); for i=1:18 block(i+1,: )=y(i*160: (i*160+blocklen-1)); end w=hamming(blocklen); for i=1:19 a=xcorr((block(i,: ).*w'),12); % finding auto correlation from lag -12 to 12 for j=1:12 auto(j,: )=fliplr(a(j+1:j+12)); % forming autocorrelation matrix from lag 0 to 11 end z=fliplr(a(1:12)); % forming a column matrix of autocorrelations for lags 1 to 12 alpha=pinv(auto)*z'; lpc(:,i)=alpha; end wavplay(x,Fs); X1=reshape(lpc,1,228); a1=sigmoid(Theta1*[1;X1']); h=sigmoid(Theta2*[1;a1]); m=max(h); p1=find(h==m); if(p1==10) P=0 else P=p1 end end[/B][/B] [/QUOTE]
Insert quotes…
Verification
Asuwa dahayen wadi kalama keeyada?
Post reply
Top
Bottom