[{"data":1,"prerenderedAt":127},["ShallowReactive",2],{"blog-post-sox-create-audio-spectrogram":3,"recent-posts":79},{"id":4,"uid":5,"url":6,"type":7,"href":8,"tags":9,"first_publication_date":10,"last_publication_date":10,"slugs":11,"linked_documents":13,"lang":14,"alternate_languages":15,"data":16},"avWO-RIAACoAxQUq","sox-create-audio-spectrogram",null,"blog_posts","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=aveTFhEAACkAjqVI&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22avWO-RIAACoAxQUq%22%29+%5D%5D",[],"2026-11-13T22:45:41+0000",[12],"sox-how-to-create-an-audio-spectrogram",[],"en-us",[],{"title":17,"date":23,"description":24,"image":29,"content":39},[18],{"type":19,"text":20,"spans":21,"direction":22},"heading1","SoX: How to Create an Audio Spectrogram",[],"ltr","2026-11-13",[25],{"type":26,"text":27,"spans":28,"direction":22},"heading2","Learn how to create an audio spectrogram using SoX",[],{"dimensions":30,"alt":6,"copyright":6,"url":33,"id":34,"edit":35},{"width":31,"height":32},1280,720,"https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002Fxz2bHoi8Kxbt2U3m_soxspectrogramthumb.jpg?auto=format,compress","xz2bHoi8Kxbt2U3m",{"x":36,"y":36,"zoom":37,"background":38},0,1,"transparent",[40,44,47,51,54,57,60,63,66,69,72,76],{"type":41,"text":42,"spans":43,"direction":22},"paragraph","Before we get started, make sure you have Homebrew installed and an audio file ready to go, such as a WAV file.",[],{"type":41,"text":45,"spans":46,"direction":22},"First, open your Terminal by pressing \u003Ccode>command + space\u003C\u002Fcode>, typing Terminal, and hitting enter. Install SoX using Homebrew by running:",[],{"type":48,"text":49,"spans":50,"direction":22},"preformatted","brew install sox",[],{"type":41,"text":52,"spans":53,"direction":22},"This might take a minute to download and set up, so just wait until your command prompt returns.",[],{"type":41,"text":55,"spans":56,"direction":22},"Next, use the \u003Ccode>cd\u003C\u002Fcode> command to navigate to the folder where your audio file is saved. Once you are in the right folder, run this command to generate your spectrogram:",[],{"type":48,"text":58,"spans":59,"direction":22},"sox input.wav -n spectrogram -o spectrogram.png",[],{"type":41,"text":61,"spans":62,"direction":22},"Just replace \u003Ccode>input.wav\u003C\u002Fcode> with your actual file name. Notice the \u003Ccode>-n\u003C\u002Fcode> flag in the middle; that tells SoX not to output a new audio file, since we only want the image.",[],{"type":41,"text":64,"spans":65,"direction":22},"If you want to add a custom title to the top of your image, just include the \u003Ccode>-t\u003C\u002Fcode> flag at the end like this:",[],{"type":48,"text":67,"spans":68,"direction":22},"sox input.wav -n spectrogram -o spectrogram.png -t \"My Title\"",[],{"type":41,"text":70,"spans":71,"direction":22},"To confirm everything worked, run \u003Ccode>open spectrogram.png\u003C\u002Fcode> to view your new image. You should see a detailed visual chart showing your audio frequencies over time.",[],{"type":73,"oembed":74},"embed",{"embed_url":75,"type":73},"",{"type":41,"text":77,"spans":78,"direction":22},"You can customize the exact pixel size of your chart by adding \u003Ccode>-x\u003C\u002Fcode> for width and \u003Ccode>-y\u003C\u002Fcode> for height right after the \u003Ccode>spectrogram\u003C\u002Fcode> keyword.",[],{"results":80,"page":37,"results_per_page":125,"results_size":125,"total_results_size":126,"total_pages":37},[81,83,102],{"id":4,"uid":5,"url":6,"type":7,"href":8,"tags":9,"first_publication_date":10,"last_publication_date":10,"slugs":11,"linked_documents":13,"lang":14,"alternate_languages":15,"data":82},{"image":29,"title":17},{"id":84,"uid":85,"url":6,"type":7,"href":86,"tags":87,"first_publication_date":10,"last_publication_date":10,"slugs":88,"linked_documents":90,"lang":14,"alternate_languages":91,"data":92},"avWQnBIAACkAxQkN","sox-change-audio-sample-rate","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=aveTFhEAACkAjqVI&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22avWQnBIAACkAxQkN%22%29+%5D%5D",[],[89],"sox-how-to-change-audio-sample-rate",[],[],{"image":93,"title":98},{"dimensions":94,"alt":6,"copyright":6,"url":95,"id":96,"edit":97},{"width":31,"height":32},"https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002FILabK-ApIRqHP1dD_samplerate.png?auto=format,compress","ILabK-ApIRqHP1dD",{"x":36,"y":36,"zoom":37,"background":38},[99],{"type":19,"text":100,"spans":101,"direction":22},"SoX: How to Change Audio Sample Rate",[],{"id":103,"uid":104,"url":6,"type":7,"href":105,"tags":106,"first_publication_date":107,"last_publication_date":108,"slugs":109,"linked_documents":111,"lang":14,"alternate_languages":112,"data":113},"avV_qhIAACgAxOVE","sox-fade-in-fade-out-audio","https:\u002F\u002Fmarks-personal-website.cdn.prismic.io\u002Fapi\u002Fv2\u002Fdocuments\u002Fsearch?ref=aveTFhEAACkAjqVI&q=%5B%5B%3Ad+%3D+at%28document.id%2C+%22avV_qhIAACgAxOVE%22%29+%5D%5D",[],"2026-11-12T09:09:07+0000","2026-11-13T18:44:52+0000",[110],"sox-how-to-add-fade-in--fade-out-to-audio",[],[],{"image":114,"title":121},{"dimensions":115,"alt":6,"copyright":6,"url":118,"id":119,"edit":120},{"width":116,"height":117},1376,768,"https:\u002F\u002Fimages.prismic.io\u002Fmarks-personal-website\u002Fh-qeKr1k78EgiZok_SoX-HowtoAddFade-InandFade-OuttoAudio.jpg?auto=format,compress","h-qeKr1k78EgiZok",{"x":36,"y":36,"zoom":37,"background":38},[122],{"type":19,"text":123,"spans":124,"direction":22},"SoX: How to Add Fade-In & Fade-Out to Audio",[],3,49,1794609967408]