美國有一半買黑膠的人沒有黑膠唱盤

Hacker News 上看到討論美國很多人買黑膠卻沒有黑膠唱盤:「Half of vinyl buyers in the U.S. don’t have a record player: study (consequence.net)」,原文在「Half of Vinyl Buyers in the US Don’t Have a Record Player, New Study Shows」這。

其實現代還蠻多人買黑膠不是要聽的,有很多其他用途啊,像是可以當作大型簽名板 XD

我都跟朋友說買黑膠是買一張小海報,又好保存...

直接用 prompt 產生音樂的 Riffusion

很紅的 Stable Diffusion 是寫一串文字 (prompt) 然後產生圖片,而 Riffusion 則是寫一串文字產生音樂。

其中 prompt 轉成音樂其實還在可以預期的範圍 (i.e. 遲早會出現),但專案的頁面上解釋了 Riffusion 是基於 Stable Fusion 的作品,而且是利用 Stable Fusion 產生出時頻譜 (spectrogram):

Well, we fine-tuned the model to generate images of spectrograms, like this:

也就是像這樣的圖:

Hacker News 上討論時的討論頁可以看看,作者有參與一些討論:「Riffusion – Stable Diffusion fine-tuned to generate music (riffusion.com)」。

其中有人提到這個作法超出想像,因為輸出的圖片只要幾個 pixel 差一點點就會產生出很不同的聲音:

This really is unreasonably effective. Spectrograms are a lot less forgiving of minor errors than a painting. Move a brush stroke up or down a few pixels, you probably won't notice. Move a spectral element up or down a bit and you have a completely different sound. I don't understand how this can possibly be precise enough to generate anything close to a cohesive output.

Absolutely blows my mind.

然後其中一位作者回覆到,他也是做下去後才很意外發現居然可行:

Author here: We were blown away too. This project started with a question in our minds about whether it was even possible for the stable diffusion model architecture to output something with the level of fidelity needed for the resulting audio to sound reasonable.

實際上聽了產生出來的音樂,是真的還 OK 的音樂... 大家都完全沒想到可以這樣搞,然後在 Hacker News 上的 upvote 數量爆炸高 XD

Psst:Open Source 且非 Electron 版本的 Spotify 播放器

前幾天在 Hacker News 首頁上看到的東西,而且也是當天熱度超高的話題,Open Source 且非 Electron 版本的 Spotify 播放器 Psst:「Psst: Fast Spotify client with native GUI, without Electron, built in Rust (github.com/jpochyla)」。

因為使用 Rust 與 native GUI library,加上沒有一堆 Spotify 內建的廣告系統,整個速度快到爆炸 XDDD

專案的擁有者 jpochyla 在「make provided binaries more prominent #89」這邊有提到有 nightly build 可以用:「nightly.link | Repository jpochyla/psst | Workflow build.yml | Branch master」,不過我抓下來發現不會動,所以就自己花了些時間編看看...

剛被推上 Hacker News 的時候 README.md 上的指示還沒那麼清楚,編不起來,後來這兩天陸陸續續被修正了。

桌機是 Ubuntu 20.04,而用 Ubuntu 20.04 內包的 rustc (1.51.0) 是沒辦法編的,需要自己先透過 rustup 裝新版 1.54.0 來編,基本上照著 README.md 的指示先把 dependency 裝起來,然後照著對應的指令操作就可以了。

這樣之後聽音樂方便不少...

Apple 與 Amazon 都要推出無損版的音樂串流服務了

首先是 Apple 宣佈了無損的音樂串流服務,不另外加價:「Apple Music Launching Spatial Audio With Dolby Atmos and Lossless Audio in June at No Extra Cost」,官方新聞稿在「Apple Music announces Spatial Audio with Dolby Atmos; will bring Lossless Audio to entire catalog」。

再來是 Amazon 也宣佈跟上,本來就有提供無損的 Amazon Music HD 下放到 Amazon Music Unlimited 方案也可以聽了:「Amazon Music Matching Apple by Offering Hi-Fi Tier at No Extra Cost」。

這對 Spotify 的壓力應該不小,畢竟已經先宣佈會推出無損版,但卻反而先被競爭對手出招先行制定價錢了...

Square 入主 Tidal

金流產業的 Square 買了音樂產業的 Tidal 大量股份,入主 Tidal:「Square to Buy Majority Stake in Jay-Z’s Tidal Music Streaming Platform」,TechCrunch 也有報導:「Square buys majority of Tidal, adds Jay Z to its board in bid to shake up the artist economy」。

這次的入股包括現金與股票交換,同時也讓 Jay-Z 成為 Square 的董事:

Square Inc. is buying a majority stake in Tidal, a music and entertainment platform owned by rapper Shawn “Jay-Z” Carter and other artists, for $297 million in cash and stock.

The deal also installs musician and businessperson Jay Z on Square’s board.

Square 跟 Tidal 的組合想像起來有點累,這算盤不知道怎麼打...

freeDB 將在明年三月底關閉

Hacker News 上看到的消息,提供 CD 資訊的 freeDB 將在明年三月底關閉:「FreeDB Is Shutting Down (freedb.org)」。

freeDB 的關閉算是一段歷史的終章,實際對使用者的影響應該不算大,一方面是 CD 的銷量逐漸下滑,另外一方面是因為現在的程式大多數會同時支援 freeDB 與 MusicBrainz (如果翻一下歷史的話,會注意到後者本來就是因為 freeDB 的授權結構而另外發展出來的服務)。

現在幾乎都是用串流服務與 YouTube 了...

AWS 展示了 DeepComposer

今年 AWSre:Invent 又開始了,照慣例有很多東西會在會場上發表 (尤其是現場表演起來會很炫的),其中一個是 AWS DeepComposer:「AWS DeepComposer – Compose Music with Generative Machine Learning Models」。

在現場有人錄影下來放到 Twitter 上可以直接看:

現場展示了輸入一段旋律,而 AWS DeepComposer 可以補上其他樂器的配樂。在 blog 上的介紹文章也可以看到同樣的說明:

  • Log into the DeepComposer console,
  • Record a short musical tune, or use a prerecorded one,
  • Select a generative model for your favorite genre, either pretrained or your own,
  • Use this model to generate a new polyphonic composition,
  • Play the composition in the console,
  • Export the composition or share it on SoundCloud.

就... 很炫 XD

Spotify 向歐盟投訴 Apple Music 的不公平競爭

Spotify 向歐盟提出不公平競爭的投訴,並且發出新聞稿:「Consumers and Innovators Win on a Level Playing Field」。

重點在於 Spotify 服務透過蘋果的平台會有 30% 的抽成,但 Apple Music 因為自家服務而不需要:

To illustrate what I mean, let me share a few examples. Apple requires that Spotify and other digital services pay a 30% tax on purchases made through Apple’s payment system, including upgrading from our Free to our Premium service. If we pay this tax, it would force us to artificially inflate the price of our Premium membership well above the price of Apple Music. And to keep our price competitive for our customers, that isn’t something we can do.

不過裡面好像沒提到超過一年後的費用會降到 15% (參考「Auto-renewable Subscriptions」),應該會是蘋果向歐盟回應的重點?

又一個 TCP BBR 的測試結果

TCP BBRGoogle 發表的 TCP congestion control 演算法,是一個純伺服器端就能夠改善 TCP 壅塞處理的機制。在 Linux Kernel 4.9 之後被納入了。

Spotify 有大量資料要傳到使用者端 (像是音檔),剛好是 TCP BBR 改善的對象之一,實際測試後得到了很不錯的改善數據:「Smoother Streaming with BBR」。

Spotify 公佈的資料沒有提到平台,所以先稍微了解一下他的音質,也就是「Audio settings」這篇。

在 Desktop 是 160kbps/320kbps Ogg (Standard/HQ)。在 Web Player 則是 128kbps/256kbps AAC (Standard/HQ)。

行動平台部份比較複雜,在 iOS 上是 96kbps/160kbps/256kbps Ogg (Normal/High/Extreme),另外有 Automatic 自動調整的設定。在 Android 平台則是 24kbps HE-AACv2 (Low) 與 96kbps/160kbps/320kbps Ogg (Normal/High/Very high) 以及 Automatic。

而最後 Chromecast 則是 128kbps/256kbps (Standard/Premium)。

測試時可以發現 shutter (指跟不上播放速度) 的情況降低了 6%~10%,而且下載速度增加了 5%~7% (對於慢速的裝置改善更多,10%~15%):

Taking daily averages, stutter decreased 6-10% for the BBR group. Bandwidth increased by 10-15% for the slower download cohorts, and by 5-7% for the median. There was no difference in latency between groups.

而各地區的差異也可以看出來改善很多:

另外他們在測試時,剛好遇到秘魯的機房連外發生問題,結果意外發現 BBR 還是可以穩定在這種網路環境下運作:

In Peru, the non-BBR group saw a 400-500% increase in stutter. In the BBR group, stutter only increased 30-50%.

In this scenario, the BBR group had 4x bandwidth for slower downloads (the 10th percentile), 2x higher median bandwidth, and 5x less stutter!

Ubuntu 18.04 上可以直接設定 BBR,在 Ubuntu 16.04 則可以參考「Ubuntu 16.04 用 speedtest-cli 測試 TCP BBR 效能」這篇的方式升級 kernel 後設定 BBR。

MP3 專利全數過期

看到有人提到,查了維基百科上面的 MP3 條目,看起來在 4/16 就全部都過期了:

The basic MP3 decoding and encoding technology is patent-free in the European Union, all patents having expired there by 2012 at the latest. In the United States, the technology became substantially patent-free on 16 April 2017 (see below).

If the longest-running patent mentioned in the aforementioned references is taken as a measure, then the MP3 technology became patent-free in the United States on 16 April 2017 when U.S. Patent 6,009,399, held by and administered by Technicolor, expired.

The three exceptions are: U.S. Patent 5,878,080, expired February 2017; U.S. Patent 5,850,456, expired February 2017; and U.S. Patent 5,960,037, expired 9 April 2017.

算是可喜可賀?