MIT新編譯器 SySTeC:加速AI模型,慳位又慳電!

Ai




用戶友好的系統可協助開發者建立更高效的模擬和人工智能模型

通過自動生成代碼,利用兩種數據冗餘,這個系統節省了帶寬、內存和計算資源。

在醫療影像處理和語音識別等應用中,使用的神經網絡人工智能模型在處理極為複雜的數據結構時,需進行大量計算。這是深度學習模型消耗大量能源的原因之一。

為了提高人工智能模型的效率,麻省理工學院的研究人員創建了一個自動化系統,使深度學習算法的開發者能夠同時利用兩種數據冗餘。這樣可以減少機器學習操作所需的計算量、帶寬和內存存儲。

現有的算法優化技術通常繁瑣,且通常僅允許開發者利用稀疏性或對稱性——這是深度學習數據結構中存在的兩種不同冗餘類型。

通過使開發者能夠從頭開始構建一個同時利用這兩種冗餘的算法,麻省理工的研究人員的方法在某些實驗中將計算速度提高了近30倍。

由於該系統利用了一種用戶友好的編程語言,它可以為各種應用優化機器學習算法。該系統還可以幫助那些不是深度學習專家的科學家,提高他們用來處理數據的人工智能算法的效率。此外,該系統還可能在科學計算中發揮作用。

“長期以來,捕捉這些數據冗餘需要大量的實施工作。相反,科學家可以以更抽象的方式告訴我們的系統他們希望計算什麼,而不需要告訴系統具體的計算方式,”麻省理工的博士後研究員、該系統論文的共同作者威洛·阿赫倫斯表示。該論文將在國際代碼生成和優化研討會上發表。

她的合著者包括主筆拉達·帕特爾和高級作者薩曼·阿馬拉辛赫,他是電機工程與計算機科學系的教授,也是計算機科學與人工智能實驗室的主要研究員。

減少計算

在機器學習中,數據通常表示為多維數組,稱為張量。張量類似於矩陣,即在兩個軸(行和列)上排列的矩形數值數組。但與二維矩陣不同,張量可以有多個維度,這使得張量的操作更加困難。

深度學習模型通過重複的矩陣乘法和加法對張量進行操作——這個過程是神經網絡學習數據中複雜模式的方式。必須對這些多維數據結構進行的計算量巨大,消耗了大量的計算和能源。

但由於張量中數據的排列方式,工程師通常可以通過刪除冗餘計算來提高神經網絡的速度。

例如,如果一個張量表示來自電子商務網站的用戶評價數據,由於並非每個用戶都對每個產品進行評價,因此該張量中的大多數值可能為零。這種數據冗餘被稱為稀疏性。模型可以通過僅存儲和操作非零值來節省時間和計算。

此外,有時張量是對稱的,這意味著數據結構的上半部分和下半部分是相等的。在這種情況下,模型僅需對一半進行操作,從而減少計算量。這種類型的數據冗餘被稱為對稱性。

“不過,當你試圖同時捕捉這兩種優化時,情況會變得相當複雜,”阿赫倫斯說。

為了簡化這一過程,她和她的合作者建立了一個新的編譯器,這是一種將複雜代碼轉換為機器可處理的簡單語言的計算機程序。他們的編譯器名為SySTeC,可以通過自動利用張量中的稀疏性和對稱性來優化計算。

他們開始構建SySTeC的過程中,確定了可以通過對稱性進行的三個關鍵優化。

首先,如果算法的輸出張量是對稱的,那麼只需要計算一半。其次,如果輸入張量是對稱的,那麼算法只需要讀取一半。最後,如果張量操作的中間結果是對稱的,算法可以跳過冗餘計算。

同時優化

使用SySTeC時,開發者輸入他們的程序,系統自動為所有三種類型的對稱性優化代碼。然後SySTeC的第二階段進行額外的轉換,只存儲非零數據值,從而優化程序的稀疏性。

最終,SySTeC生成即用的代碼。

“這樣,我們就能獲得兩種優化的好處。而且,對稱性的一個有趣之處在於,隨著張量的維度增加,你可以獲得更多的計算節省,”阿赫倫斯表示。

研究人員展示了通過SySTeC自動生成的代碼,計算速度提高了近30倍。

由於該系統是自動化的,因此在科學家希望使用他們從零開始編寫的算法處理數據的情況下,它特別有用。

未來,研究人員希望將SySTeC整合進現有的稀疏張量編譯器系統,以為用戶創建無縫的界面。此外,他們還希望利用它來優化更複雜程序的代碼。

這項工作部分由英特爾、國家科學基金會、國防高級研究計劃局和能源部資助。

這項研究展示了人工智能和計算科學的前沿進展,特別是如何通過簡化編程過程來提高計算效率。隨著數據量的急劇增加,這種能夠自動優化計算的系統將成為未來科研和商業應用中的重要工具。尤其是對於那些並不精通深度學習的科學家,這樣的工具將使他們能夠更便捷地處理和分析數據,進一步推動各領域的創新和發展。

以上文章由特價GPT API KEY所翻譯及撰寫。而圖片則由FLUX根據內容自動生成。

🎨 Nano Banana Pro 圖像生成器|打幾句說話就出圖

想畫人像、產品圖、插畫?SSFuture 圖像生成器支援 Flux Gemini Nano Banana Pro 改圖 / 合成, 打廣東話都得,仲可以沿用上一張圖繼續微調。

🆓 Flux 模型即玩,不用登入
🤖 登入後解鎖 Gemini 改圖
📷 支援上載參考圖再生成
⚡ 每天免費額度任你玩
✨ 即刻玩 AI 畫圖
Base Setup
keep 100 percent facial information adherence of the attached image and turn her into a girl standing beneath autumn leaves outside a traditional wooden structure in a live action photograph or movie still, wearing a complex suggestive outfit that harmonizes with the warm fall tones.

Shot and Camera
Three quarter shot at slightly low height, framing her off center to the right so the yellow leaves and carved wooden panels dominate the left. Maintain the intimate close framing and vertical orientation feel of the reference.

Identity and Pose
Preserve her age read, build, silhouette, hairstyle length, and skin tone. She leans lightly against the doorframe, one hand grazing a hanging leaf, her posture relaxed and candid, 8k Photorealistic and hyper realistic.

Lighting and Environment
Soft warm daylight filters through the leaves, casting dappled highlights on her hair and outfit. Ground her feet on aged wooden flooring with natural grain, faint scuffs, and subtle contact shadows.

Masking and Constraints
Change only wardrobe and placement while keeping lighting, perspective, white balance, pose, face geometry, body proportions, and silhouette the same. Absolutely no added text, no CGI look, no plastic skin, no floating feet, with consistent perspective and correct contact shadows. Base Setup
keep 100 percent facial information adherence of the attached image and turn her into a lone traveler posed on a sunlit desert dune ridge, captured as a live action photograph or movie still, not an illustration or CGI render, with a sexy, confident, heat soaked editorial mood.

Shot and Camera
Full body shot from slightly low height, framing her on the right third, with sweeping dunes rolling into the distance on the left, using a wide cinematic lens feel that keeps the landscape vast and minimal.

Identity and Pose
She has a slim, toned build, medium height impression, sun kissed skin, and long loose hair blown by the wind. She stands barefoot on the crest, one leg forward so the hip shifts naturally, one hand resting on her upper thigh and the other lightly gripping a sheer wrap at her side, wearing a high cut desert bikini with a gauzy open sarong that shows plenty of leg and midriff without nudity, head turned over her shoulder with a subtle, knowing smile, 8k Photorealistic and hyper realistic.

Lighting and Environment
Harsh midday sun from high right casts crisp shadows along her body and the dune ripples, with soft sky bounce filling the shadows enough to keep detail. The sand textures, wind carved ridges, and pale blue sky remain exactly like the reference, with faint footprints and slight imperfections grounding her on the slope.

Masking and Constraints
Change only by adding the subject and her wardrobe, keep dune shapes, lighting direction, perspective, horizon line, and white balance identical, preserving realistic body proportions and clear contact between her feet and the sand. Absolutely no added text, no painterly or toon look, no CGI plastic skin, no see through fabric on intimate areas, no warped limbs or floating feet, strictly require consistent perspective, natural film like grain, fine skin texture and sand detail, and physically correct contact shadows in the sand depressions around her feet. Highly detailed, artistic illustration of two cats sitting together on the bustling Nathan Road in Hong Kong. One cat is a sleek black feline with emerald green eyes, the other is a fluffy ginger tabby with white paws. They are perched near the neon-lit storefronts and glowing billboards, surrounded by vibrant city life: crowds of people, bright taxis, and street vendors selling local food. The scene is alive with colorful reflections on rain-slicked pavement, atmospheric mist, and dramatic lighting from neon signs in Chinese characters. The artistry should blend urban realism with a touch of whimsical charm, focusing on the cats' expressive faces and the dynamic ambiance of Nathan Road at night.