IntelAMD GPU 直接跑 CUDA 程式的 ZLUDA

先前提過「在 Intel 內顯上面直接跑 CUDA 程式的 ZLUDA」,結果後來事情大翻轉,AMD 跑去贊助專案,變成支援 AMD GPU 了:「AMD Quietly Funded A Drop-In CUDA Implementation Built On ROCm: It's Now Open-Source」,專案在 GitHubvosen/ZLUDA 這邊,而這包支援 AMD GPU 的 commit log 則是在 1b9ba2b2333746c5e2b05a2bf24fa6ec3828dcdf 這包巨大的 commit:

Nobody expects the Red Team

Too many changes to list, but broadly:
* Remove Intel GPU support from the compiler
* Add AMD GPU support to the compiler
* Remove Intel GPU host code
* Add AMD GPU host code
* More device instructions. From 40 to 68
* More host functions. From 48 to 184
* Add proof of concept implementation of OptiX framework
* Add minimal support of cuDNN, cuBLAS, cuSPARSE, cuFFT, NCCL, NVML
* Improve ZLUDA launcher for Windows

其中的轉折以及後續的故事其實還蠻不知道怎麼說的... 作者一開始在 Intel 上班,弄一弄 Intel 覺得這沒前景,然後 AMD 接觸後贊助這個專案,到後面也覺得沒前景,於是依照後來跟 AMD 的合約,如果 AMD 覺得沒前景,可以 open source 出來:

Why is this project suddenly back after 3 years? What happened to Intel GPU support?

In 2021 I was contacted by Intel about the development od ZLUDA. I was an Intel employee at the time. While we were building a case for ZLUDA internally, I was asked for a far-reaching discretion: not to advertise the fact that Intel was evaluating ZLUDA and definitely not to make any commits to the public ZLUDA repo. After some deliberation, Intel decided that there is no business case for running CUDA applications on Intel GPUs.

Shortly thereafter I got in contact with AMD and in early 2022 I have left Intel and signed a ZLUDA development contract with AMD. Once again I was asked for a far-reaching discretion: not to advertise the fact that AMD is evaluating ZLUDA and definitely not to make any commits to the public ZLUDA repo. After two years of development and some deliberation, AMD decided that there is no business case for running CUDA applications on AMD GPUs.

One of the terms of my contract with AMD was that if AMD did not find it fit for further development, I could release it. Which brings us to today.

這個其實還蠻好理解的,CUDA 畢竟是 Nvidia 家的 ecosystem,除非你反超越後自己定義一堆自家專屬的功能 (像是當年 MicrosoftIE 上的玩法),不然只是幫人抬轎。

Phoronix 在 open source 前幾天先拿到軟體進行測試,而他這幾天測試的結果給了「頗不賴」的評價:

Andrzej Janik reached out and provided access to the new ZLUDA implementation for AMD ROCm to allow me to test it out and benchmark it in advance of today's planned public announcement. I've been testing it out for a few days and it's been a positive experience: CUDA-enabled software indeed running atop ROCm and without any changes. Even proprietary renderers and the like working with this "CUDA on Radeon" implementation.

另外為了避免測試時有些測試軟體會回傳到伺服器造成資訊外洩,ZLUDA 在這邊故意設定為 Graphics Device,而在這次 open source 公開後會改回正式的名稱:

In my screenshots and for the past two years of development the exposed device name for Radeon GPUs via CUDA has just been "Graphics Device" rather than the actual AMD Radeon graphics adapter with ROCm. The reason for this has been due to CUDA benchmarks auto-reporting results and other software that may have automated telemetry, to avoid leaking the fact of Radeon GPU use under CUDA, it's been set to the generic "Graphics Device" string. I'm told as part of today's open-sourcing of this ZLUDA on Radeon code that the change will be in place to expose the actual Radeon graphics card string rather than the generic "Graphics Device" concealer.

作者的測試看起來在不同的測試項目下差異頗大,但如果依照作者的計算方式,整體效能跟 OpenCL 版本差不多:

Phoronix 那邊則是做了與 Nvidia 比較的測試... 這邊拿的是同樣都有支援 Nvidia 與 AMD 家的卡的 Blender 測試,然後跑出來的結果讓人傻眼,透過 ZLUDA 轉譯出來的速度比原生支援的速度還快,這 optimization 看起來又有得討論了:(這是 BMW27 的測試,在 Classroom 的測試也發現一樣的情況)

但即使如此,CUDA over AMD GPU 應該還是不會起來,官方會儘量讓各 framework 原生支援,而大多數的開發者都是在 framework 上面開發,很少會自己從頭幹...

Bluesky 開放一般註冊了

Bluesky 宣佈開放一般註冊了,不再需要邀請碼:「Join Bluesky Today (Bye, Invites!)」。

想玩的先前應該都拿到邀請註冊過了,現在不知道會有什麼新的玩意出來。

對玩技術的人來說,就只是另外一個 protocol,而且目前沒什麼分散性;對一般人來說,就只是另外一個社群... 重點還是在怎麼經營吸引人。

Bluesky 支援 RSS 2.0

在「Bluesky has launched RSS feeds (openrss.org)」這邊看到 Bluesky 支援 RSS 2.0 的消息:「Bluesky has launched RSS feeds」。

以作者提到的例子來說,Jay Graber 的頁面上 (在「@jay.bsky.team on Bluesky」這邊) 有 auto-discovery link:

<link rel="alternate" type="application/rss+xml" href="https://bsky.app/profile/did:plc:oky5czdrnfjpqslsw2a5iclo/rss">

選擇 RSS 2.0 而不是 Atom,不知道是什麼原因...

有了 feed 以後現有的 RSS reader 都可以直接訂起來了,像是在 Slack 上可以用 /feed add [url] 訂閱。

Tumblr 的 ActivityPub 進度

先前在「Threads 要放 ActivityPub 了?」這篇提到 Threads 要放行 ActivityPub,剛剛想到 Tumblr 這邊不知道在 re-org 後有什麼新消息,然後翻到 Matt Mullenweg 在 Tumblr 寫了 這篇

主要是交代有指派人做這件事情,但也先舖了一些理由... 所以看看 2024Q1 有沒有機會看到些東西?

Netflix 放出了 2023 上半年一萬八千部的播放統計資料

在「What We Watched: A Netflix engagement report (netflix.com)」這邊看到的,Netflix 的文章在「What We Watched: A Netflix Engagement Report」這邊,標題提到的 Excel 報告在 What_We_Watched_A_Netflix_Engagement_Report_2023Jan-Jun.xlsx 這邊。

Hacker News 上的留言 id=38621625 有提到這是 Writers Guild of America 的聯合罷工 (參考英文維基百科的「2023 Writers Guild of America strike」或是中文維基百科「2023年美國編劇協會大罷工」) 所協商出來的成果:

This is an outcome of the WGA strike negotiations. Now writers (and actors, and anyone else) can use this information to better negotiate their worth with studios, rather than it being 1-sided. All other streaming services should be following suit soon.

在「What We Won」這邊可以看到關於 transparency 的部分:

Streaming data transparency: Companies agree to provide the Guild, subject to a confidentiality agreement, the total number of hours streamed, both domestically and internationally, of self-produced high budget streaming programs (e.g., a Netflix original series). Aggregated information can be shared.

打開 Excel 檔可以看到 Netflix 就放出最低限度的資料,但就如同 comment 提到的,這份資料以及足以讓很多人有機會反過來談更好的合約。

另外一方面,也可以預期這份公開資料交叉其他的 metadata 可以分析出一些有趣的東西?

HashiCorp 的 Vault 也有 fork 了:OpenBao

當初 HashiCorp 宣布改 license (可以參考之前寫的「HashiCorp 將放棄 Open Source License,改採用 BSL 1.1」),用的最多的 Terraform 就馬上有人 fork 出來:「OpenTF 宣佈從 Terraform 最後一個 Open Source 版本 fork 出來」、「OpenTF (Terraform 的 fork) 改名為 OpenTofu」。

Vault 也受到影響,當時花了一些時間找看看有沒有人 fork,沒找到後就改用 etcd (然後搭配 etcd-adminer 以及 oauth2-proxyGoogle Workspace 的 SSO),後來就沒有追這個問題了...

剛剛才看到 fork 的消息出來了:「OpenBao – FOSS Fork of HashiCorp Vault (github.com/openbao)」,專案在「OpenBao」這邊,要注意目前只有 development branch 有東西,main branch 目前是空的,而且 Hacker News 上討論也有提到現在還在 early stage,很多東西都還在整理。

之後有機會再回來看看...

Sentry 的 License 不是 Open Source License...

前一篇「Sentry 的替代品:GlitchTip」我自己提到:

Sentry 本身已經是 open source software 了

結果在 HN 上面馬上就看到討論:「Sentry: From the Beginning (cra.mr)」,其中 id=38097463 這邊提到:

The article doesn't appear to mention that Sentry abandoned open source.

LICENSE 這個檔案的記錄 History for LICENSE 裡慢慢翻,可以翻到 Apache License, Version 2.0 是在 2589cbef43659151e70fd3d20eb8b34d7f1f574f (2019/06/11) 這邊加進去的,而變成 BSL 是在 e2b7c743af70e192588d843512412e653eddab17 (2019/11/07) 這邊發生的,另外也有對應的 blog 文章:「Re-Licensing Sentry」。

Uptime Kuma:UptimeRobot 的 Open Source Clone

UptimeRobot 算是我自己還蠻喜歡用的監控服務,各種常見的類型都支援,像是 HTTP/HTTPS website 的監控,ICMP Ping 或是 TCP 的監控,另外也提供 SSL certificate 的監控。

前陣子找資料的時候找到 Uptime Kuma,這是香港的 Louis Lam 開發的 open source software,光看名字就懷疑是 UptimeRobot 的致敬版本,裝起來用過後就更確定...

差不多用了一個多月了,基本上功能還蠻完整的,我把他接到我自己的 Slack 以及 Pushover 上,就很方便的可以監控服務:

挑一個點:

原來 OSI 有寫過 LLaMA 的 license 不是 open source license 的宣告

MetaLLaMA 宣稱是「The next generation of our open source large language model」,而 OSI 很早就有發文駁斥:「Meta’s LLaMa 2 license is not Open Source」。

在 OSI 的網站上可以看到「The Open Source Definition」,其中這條:

6. No Discrimination Against Fields of Endeavor

The license must not restrict anyone from making use of the program in a specific field of endeavor. For example, it may not restrict the program from being used in a business, or from being used for genetic research.

open source 不能限制使用,而 LLaMA 的授權限制了商業使用:

2. Additional Commercial Terms. If, on the Llama 2 version release date, the monthly active users of the products or services made available by or for Licensee, or Licensee’s affiliates, is greater than 700 million monthly active users in the preceding calendar month, you must request a license from Meta, which Meta may grant to you in its sole discretion, and you are not authorized to exercise any of the rights under this Agreement unless or until Meta otherwise expressly grants you such rights.

前幾天翻車的 CKIP-Llama-2-7b 目前都已經下架了,但可以在 Archive Today 的「CKIP Llama 2 7b Chat - a Hugging Face Space by ckiplab」看到存檔頁面,以及在 Internet Archive 上的「GitHub - ckiplab/CKIP-Llama-2-7b: CKIP Traditional Chinese Llama-2」看到 GitHub 當時的頁面。

當時看到 CKIP-Llama-2-7b 宣稱用 Apache License, Version 2.0 放出來,我就「蛤?」了出來...

Anyway,雖然是其他原因被下架了...

目前最老的 BitTorrent 種子 20 年了:The Fanimatrix

The FanimatrixBitTorrent 種子是目前還活著的 BitTorrent 種子最老的,從 2003 年九月建立的種子,至今要 20 年了:「The World’s Oldest Active Torrent Turns 20 Years Old」。

在 2022 的報告裡面 BitTorrent 的流量大約是 2.91% (雖然這份報告本身有些地方很詭異,但就還是可以當個參考):「2022 Global Internet Phenomena Report」,在「BitTorrent is Still the King of Upstream Internet Traffic, But for How Long?」這邊也在討論 BitTorrent 的占比逐漸下降。

但這就是 open protocol 的特性,你沒辦法殺掉他,而且他在對應的領域還是活的很好...