SlideShare a Scribd company logo
3/3/2014
1
Praktikum Pengenalan Bahasa Alami
Pertemuan Pertama: Pengenalan FungsiDasar PemrosesanSuara di Matlab
Departemen Ilmu Komputer
Fakultas Matematika dan Ilmu Pengetahuan Alam
Institut Pertanian Bogor
Fungsi wavrecord
• Digunakan untuk merekam suara
– y = wavrecord(n, Fs)
– y = wavrecord(…, ch)
– y = wavrecord(…, ‘dtype’)
3/3/2014
2
• y = wavrecord(n,Fs)
• Merekam sebanyak n sampel sinyal audio.
• Jumlah titik sampel per detik sebanyak Fs.
• Nilai default Fs ialah 11025 Hz.
• y = wavrecord(...,ch)
• Menggunakan sebanyak ch kanal input dari perangkat audio.
• Mono: ch bernilai 1.
• Stereo: ch bernilai 2.
• Nilai default ch ialah 1.
Parameter Fs dan ch
• y = wavrecord(...,'dtype')
• Menggunakan tipe data tertentu untuk menyimpan nilai
suara pada setiap titik sampel.
• ‘dtype’ dapat bernilai:
• ‘double’ -> 16 bit per titik sampel (nilai default).
• ‘single‘ -> 16 bit per titik sampel.
• ‘int16’ -> 16 bit per titik sampel.
• ‘uint8’ -> 8 bit per titik sampel.
Parameter dtype
DTYPE Bits/sample Y's Data range
-------- ----------- --------------------
'double' 16 -1.0 <= Y < +1.0
'single' 16 -1.0 <= Y < +1.0
'int16' 16 -32768 <= Y <= +32767
'uint8' 8 0 <= Y <= 255
3/3/2014
3
• Jumlah pengambilan titik sampel suara dalam per
detik.
• Nilai standar yang digunakan: 8000, 11025, 22050,
dan 44100 titik sampel per detik.
• Setiap titik sampel pada suara stereo terdiri atas dua
buah nilai, sementara suara mono hanya satu nilai.
• Kolom pertama suara audio akan diperdengarkan di
bagian kiri perangkat, sedangkan kolom kedua
diperdengarkan di bagian kanan perangkat.
Sampling Rate
Contoh
• X1 = wavrecord(5*11000,11000)
• Merekam 11000 titik sampel per detik, selama 5 detik.
• X2 = wavrecord(5*11000,11000, 2)
• Menggunakan tipe suara stereo.
• Using 2 channels  stereo
• X3 = wavrecord(5*11000,11000, ‘uint8’)
• Menggunakan unsigned integer 8 bit.
• Nilai per sampel maksimum sebesar 255.
3/3/2014
4
• Memainkan berkas suara yang tersimpan di vektor y
• wavplay(y, Fs)
• wavplay(…,’mode’)
• Sampling rate ditentukan oleh Fs.
• Nilai default: 11025 Hz.
• Dapat memainkan audio mono maupun stereo.
• Jika stereo, y harus berupa matriks dua kolom.
wavplay
• wavplay(...,'mode') specifies how wavplay interacts with
the command line, according the string 'mode'.
• The string 'mode' can be:
– 'async' (default value): You have immediate access to the
command line as soon as the sound begins to play on the
audio output device (a nonblocking device call).
– 'sync': You don't have access to the command line until the
sound has finished playing (a blocking device call).
wavplay
3/3/2014
5
• wavplay(X1,11000)
• wavplay(X2,11000)
• wavplay(X3,11000)
Contoh Penggunaan
• Menggunakan fungsi plot di Matlab
• Contoh:
• x=wavrecord(5*44000,44000);
• plot(x);
• y=wavrecord(5*44000,44000,2);
• figure, plot(y(:,1))
• hold on
• plot(y(:,2),'g')
• hold off
Plot
Menampilkan dalam
satu figure multiple
signal
3/3/2014
6
Plot
Plot
3/3/2014
7
• Fungsi untuk menyimpan suara ke berkas Microsoft WAVE
(.wav)
• wavwrite(y,'filename')
• wavwrite(y,Fs,'filename')
• wavwrite(y,Fs,N,'filename')
wavwrite
- Perhatikan spesifikasi saat kita merekam suara
- Lakukan kustomisasi
• wavwrite supports multi-channel WAVE data, with up 32 bits
per sample and supports writing 24- and 32-bit .wav files.
• wavwrite(y,'filename') writes a WAVE file specified by the
string filename. The data should be arranged with one channel
per column. Amplitude values outside the range [-1,+1] are
clipped prior to writing.
• wavwrite(y,Fs,'filename') specifies the sample rate Fs, in
Hertz, of the data.
• wavwrite(y,Fs,N,'filename') forces an N-bit file format to be
written, where N <= 32.
wavwrite
3/3/2014
8
• wavwrite(x,’mysignal.wav’);
Contoh
• Membaca berkas Microsoft WAVE (.wav)
• y = wavread('filename')
• [y,Fs,bits] = wavread('filename')
wavread
3/3/2014
9
• wavread supports multi-channel data, with up to 32 bits
per sample and supports reading 24- and 32-bit .wav files.
• y = wavread('filename') loads a WAVE file specified by
the string filename, returning the sampled data in y. The
.wav extension is appended if no extension is given.
Amplitude values are in the range [-1,+1].
• [y,Fs,bits] = wavread('filename') returns the sample rate
(Fs) in Hertz and the number of bits per sample (bits)
used to encode the data in the file.
wavread
Membangkitkan Sinyal
• Membangkitkan sinyal
• t = 0:0.001:1;
• x = sin(2*pi*50*t) + sin(2*pi*120*t);
• figure, plot(t,x);
• Menambahkan noise
• y = x + 0.5*randn(size(t));
• figure, plot(t, y);
3/3/2014
10
• Lakukan Perekaman Suara
- Kata : SAYA, CINTA, ILKOM, FMIPA, IPB,
- Simpan dalam format .wav
- 3 detik, Fs = 11000, mono, ‘double’
- Minggu Depan Wajib Dibawa fail tersebut
TUGAS DI RUMAH
TERIMA KASIH

More Related Content

Recently uploaded

Media Pembelajaran kelas 3 SD Materi konsep 8 arah mata angin
Media Pembelajaran kelas 3 SD Materi konsep 8 arah mata anginMedia Pembelajaran kelas 3 SD Materi konsep 8 arah mata angin
Media Pembelajaran kelas 3 SD Materi konsep 8 arah mata angin
margagurifma2023
 
KKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdeka
KKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdekaKKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdeka
KKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdeka
irvansupriadi44
 
Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]
Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]
Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]
Fathan Emran
 
ANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPAL
ANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPALANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPAL
ANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPAL
Annisa Syahfitri
 
Kelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdf
Kelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdfKelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdf
Kelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdf
JALANJALANKENYANG
 
Laporan Pembina Pramuka sd format doc.docx
Laporan Pembina Pramuka sd format doc.docxLaporan Pembina Pramuka sd format doc.docx
Laporan Pembina Pramuka sd format doc.docx
RUBEN Mbiliyora
 
Pelatihan AI GKA abdi Sabda - Apa itu AI?
Pelatihan AI GKA abdi Sabda - Apa itu AI?Pelatihan AI GKA abdi Sabda - Apa itu AI?
Pelatihan AI GKA abdi Sabda - Apa itu AI?
SABDA
 
RANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdf
RANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdfRANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdf
RANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdf
junarpudin36
 
Modul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum Merdeka
Modul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum MerdekaModul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum Merdeka
Modul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum Merdeka
Fathan Emran
 
Juknis penggunaan aplikasi ecoklit pilkada 2024
Juknis penggunaan  aplikasi ecoklit pilkada 2024Juknis penggunaan  aplikasi ecoklit pilkada 2024
Juknis penggunaan aplikasi ecoklit pilkada 2024
abdinahyan
 
Seminar Pendidikan PPG Filosofi Pendidikan.pdf
Seminar Pendidikan PPG Filosofi Pendidikan.pdfSeminar Pendidikan PPG Filosofi Pendidikan.pdf
Seminar Pendidikan PPG Filosofi Pendidikan.pdf
inganahsholihahpangs
 
ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025
ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025
ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025
PreddySilitonga
 
Panduan Penggunaan Rekomendasi Buku Sastra.pdf
Panduan Penggunaan Rekomendasi Buku Sastra.pdfPanduan Penggunaan Rekomendasi Buku Sastra.pdf
Panduan Penggunaan Rekomendasi Buku Sastra.pdf
MildayantiMildayanti
 
705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx
705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx
705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx
nimah111
 
MODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdf
MODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdfMODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdf
MODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdf
YuristaAndriyani1
 
Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...
Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...
Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...
nasrudienaulia
 
PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...
PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...
PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...
Kanaidi ken
 
2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...
2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...
2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...
PikeKusumaSantoso
 
refleksi tindak lanjut d pmm agar lebih mudah
refleksi tindak lanjut d pmm agar lebih mudahrefleksi tindak lanjut d pmm agar lebih mudah
refleksi tindak lanjut d pmm agar lebih mudah
muhamadsufii48
 
RANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptx
RANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptxRANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptx
RANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptx
SurosoSuroso19
 

Recently uploaded (20)

Media Pembelajaran kelas 3 SD Materi konsep 8 arah mata angin
Media Pembelajaran kelas 3 SD Materi konsep 8 arah mata anginMedia Pembelajaran kelas 3 SD Materi konsep 8 arah mata angin
Media Pembelajaran kelas 3 SD Materi konsep 8 arah mata angin
 
KKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdeka
KKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdekaKKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdeka
KKTP Kurikulum Merdeka sebagai Panduan dalam kurikulum merdeka
 
Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]
Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]
Modul Ajar Matematika Kelas 8 Fase D Kurikulum Merdeka - [abdiera.com]
 
ANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPAL
ANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPALANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPAL
ANALISIS PENCEMARAN UDARA AKIBAT PABRIK ASPAL
 
Kelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdf
Kelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdfKelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdf
Kelompok 2 Tugas Modul 2.1 Ruang Kolaborasi.pdf
 
Laporan Pembina Pramuka sd format doc.docx
Laporan Pembina Pramuka sd format doc.docxLaporan Pembina Pramuka sd format doc.docx
Laporan Pembina Pramuka sd format doc.docx
 
Pelatihan AI GKA abdi Sabda - Apa itu AI?
Pelatihan AI GKA abdi Sabda - Apa itu AI?Pelatihan AI GKA abdi Sabda - Apa itu AI?
Pelatihan AI GKA abdi Sabda - Apa itu AI?
 
RANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdf
RANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdfRANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdf
RANCANGAN TINDAKAN UNTUK AKSI NYATA MODUL 1.4 BUDAYA POSITIF.pdf
 
Modul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum Merdeka
Modul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum MerdekaModul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum Merdeka
Modul Ajar Bahasa Inggris Kelas 10 Fase E Kurikulum Merdeka
 
Juknis penggunaan aplikasi ecoklit pilkada 2024
Juknis penggunaan  aplikasi ecoklit pilkada 2024Juknis penggunaan  aplikasi ecoklit pilkada 2024
Juknis penggunaan aplikasi ecoklit pilkada 2024
 
Seminar Pendidikan PPG Filosofi Pendidikan.pdf
Seminar Pendidikan PPG Filosofi Pendidikan.pdfSeminar Pendidikan PPG Filosofi Pendidikan.pdf
Seminar Pendidikan PPG Filosofi Pendidikan.pdf
 
ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025
ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025
ATP Kimia Fase E Kelas X bisa deigunakan ditahun ajaran 2024/2025
 
Panduan Penggunaan Rekomendasi Buku Sastra.pdf
Panduan Penggunaan Rekomendasi Buku Sastra.pdfPanduan Penggunaan Rekomendasi Buku Sastra.pdf
Panduan Penggunaan Rekomendasi Buku Sastra.pdf
 
705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx
705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx
705368319-Ppt-Aksi-Nyata-Membuat-Rancangan-Pembelajaran-Dengan-Metode-Fonik.pptx
 
MODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdf
MODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdfMODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdf
MODUL P5 FASE B KELAS 4 MEMBUAT COBRICK.pdf
 
Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...
Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...
Teori Fungsionalisme Kulturalisasi Talcott Parsons (Dosen Pengampu : Khoirin ...
 
PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...
PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...
PELAKSANAAN + Link2 Materi Pelatihan_ PENGAWASAN P3DN & TKDN_ pd PENGADAAN Ba...
 
2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...
2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...
2. PEMBELAJARAN YANG MENGUATKAN TRANSISI PAUD-SD Merancang Instrumen Asesmen ...
 
refleksi tindak lanjut d pmm agar lebih mudah
refleksi tindak lanjut d pmm agar lebih mudahrefleksi tindak lanjut d pmm agar lebih mudah
refleksi tindak lanjut d pmm agar lebih mudah
 
RANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptx
RANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptxRANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptx
RANCANGAN TINDAKAN AKSI NYATA MODUL 1.4.pptx
 

Featured

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
Christy Abraham Joy
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
Vit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
MindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

1. pengenalan-fungsi-dasar-pemrosesan-suara-di-matlab

  • 1. 3/3/2014 1 Praktikum Pengenalan Bahasa Alami Pertemuan Pertama: Pengenalan FungsiDasar PemrosesanSuara di Matlab Departemen Ilmu Komputer Fakultas Matematika dan Ilmu Pengetahuan Alam Institut Pertanian Bogor Fungsi wavrecord • Digunakan untuk merekam suara – y = wavrecord(n, Fs) – y = wavrecord(…, ch) – y = wavrecord(…, ‘dtype’)
  • 2. 3/3/2014 2 • y = wavrecord(n,Fs) • Merekam sebanyak n sampel sinyal audio. • Jumlah titik sampel per detik sebanyak Fs. • Nilai default Fs ialah 11025 Hz. • y = wavrecord(...,ch) • Menggunakan sebanyak ch kanal input dari perangkat audio. • Mono: ch bernilai 1. • Stereo: ch bernilai 2. • Nilai default ch ialah 1. Parameter Fs dan ch • y = wavrecord(...,'dtype') • Menggunakan tipe data tertentu untuk menyimpan nilai suara pada setiap titik sampel. • ‘dtype’ dapat bernilai: • ‘double’ -> 16 bit per titik sampel (nilai default). • ‘single‘ -> 16 bit per titik sampel. • ‘int16’ -> 16 bit per titik sampel. • ‘uint8’ -> 8 bit per titik sampel. Parameter dtype DTYPE Bits/sample Y's Data range -------- ----------- -------------------- 'double' 16 -1.0 <= Y < +1.0 'single' 16 -1.0 <= Y < +1.0 'int16' 16 -32768 <= Y <= +32767 'uint8' 8 0 <= Y <= 255
  • 3. 3/3/2014 3 • Jumlah pengambilan titik sampel suara dalam per detik. • Nilai standar yang digunakan: 8000, 11025, 22050, dan 44100 titik sampel per detik. • Setiap titik sampel pada suara stereo terdiri atas dua buah nilai, sementara suara mono hanya satu nilai. • Kolom pertama suara audio akan diperdengarkan di bagian kiri perangkat, sedangkan kolom kedua diperdengarkan di bagian kanan perangkat. Sampling Rate Contoh • X1 = wavrecord(5*11000,11000) • Merekam 11000 titik sampel per detik, selama 5 detik. • X2 = wavrecord(5*11000,11000, 2) • Menggunakan tipe suara stereo. • Using 2 channels  stereo • X3 = wavrecord(5*11000,11000, ‘uint8’) • Menggunakan unsigned integer 8 bit. • Nilai per sampel maksimum sebesar 255.
  • 4. 3/3/2014 4 • Memainkan berkas suara yang tersimpan di vektor y • wavplay(y, Fs) • wavplay(…,’mode’) • Sampling rate ditentukan oleh Fs. • Nilai default: 11025 Hz. • Dapat memainkan audio mono maupun stereo. • Jika stereo, y harus berupa matriks dua kolom. wavplay • wavplay(...,'mode') specifies how wavplay interacts with the command line, according the string 'mode'. • The string 'mode' can be: – 'async' (default value): You have immediate access to the command line as soon as the sound begins to play on the audio output device (a nonblocking device call). – 'sync': You don't have access to the command line until the sound has finished playing (a blocking device call). wavplay
  • 5. 3/3/2014 5 • wavplay(X1,11000) • wavplay(X2,11000) • wavplay(X3,11000) Contoh Penggunaan • Menggunakan fungsi plot di Matlab • Contoh: • x=wavrecord(5*44000,44000); • plot(x); • y=wavrecord(5*44000,44000,2); • figure, plot(y(:,1)) • hold on • plot(y(:,2),'g') • hold off Plot Menampilkan dalam satu figure multiple signal
  • 7. 3/3/2014 7 • Fungsi untuk menyimpan suara ke berkas Microsoft WAVE (.wav) • wavwrite(y,'filename') • wavwrite(y,Fs,'filename') • wavwrite(y,Fs,N,'filename') wavwrite - Perhatikan spesifikasi saat kita merekam suara - Lakukan kustomisasi • wavwrite supports multi-channel WAVE data, with up 32 bits per sample and supports writing 24- and 32-bit .wav files. • wavwrite(y,'filename') writes a WAVE file specified by the string filename. The data should be arranged with one channel per column. Amplitude values outside the range [-1,+1] are clipped prior to writing. • wavwrite(y,Fs,'filename') specifies the sample rate Fs, in Hertz, of the data. • wavwrite(y,Fs,N,'filename') forces an N-bit file format to be written, where N <= 32. wavwrite
  • 8. 3/3/2014 8 • wavwrite(x,’mysignal.wav’); Contoh • Membaca berkas Microsoft WAVE (.wav) • y = wavread('filename') • [y,Fs,bits] = wavread('filename') wavread
  • 9. 3/3/2014 9 • wavread supports multi-channel data, with up to 32 bits per sample and supports reading 24- and 32-bit .wav files. • y = wavread('filename') loads a WAVE file specified by the string filename, returning the sampled data in y. The .wav extension is appended if no extension is given. Amplitude values are in the range [-1,+1]. • [y,Fs,bits] = wavread('filename') returns the sample rate (Fs) in Hertz and the number of bits per sample (bits) used to encode the data in the file. wavread Membangkitkan Sinyal • Membangkitkan sinyal • t = 0:0.001:1; • x = sin(2*pi*50*t) + sin(2*pi*120*t); • figure, plot(t,x); • Menambahkan noise • y = x + 0.5*randn(size(t)); • figure, plot(t, y);
  • 10. 3/3/2014 10 • Lakukan Perekaman Suara - Kata : SAYA, CINTA, ILKOM, FMIPA, IPB, - Simpan dalam format .wav - 3 detik, Fs = 11000, mono, ‘double’ - Minggu Depan Wajib Dibawa fail tersebut TUGAS DI RUMAH TERIMA KASIH