[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-1-en-105":3,"doc-seo-243895-105":53,"doc-detail-243895-en":127},{"code":4,"msg":5,"data":6},0,"success",[7,14,19,24,29,34,39,44,49],{"id":8,"doc_module":9,"doc_module_name":10,"category_name":11,"show_sort_weight":12,"slug":13},11,1,"Template","Presentations",90,"presentations",{"id":15,"doc_module":9,"doc_module_name":10,"category_name":16,"show_sort_weight":17,"slug":18},12,"Resumes",80,"resumes",{"id":20,"doc_module":9,"doc_module_name":10,"category_name":21,"show_sort_weight":22,"slug":23},14,"Invoices",70,"invoices",{"id":25,"doc_module":9,"doc_module_name":10,"category_name":26,"show_sort_weight":27,"slug":28},15,"Posters",60,"posters",{"id":30,"doc_module":9,"doc_module_name":10,"category_name":31,"show_sort_weight":32,"slug":33},16,"Social Media",50,"social-media",{"id":35,"doc_module":9,"doc_module_name":10,"category_name":36,"show_sort_weight":37,"slug":38},17,"Forms",40,"forms",{"id":40,"doc_module":9,"doc_module_name":10,"category_name":41,"show_sort_weight":42,"slug":43},18,"Letters",30,"letters",{"id":45,"doc_module":9,"doc_module_name":10,"category_name":46,"show_sort_weight":47,"slug":48},21,"Paper Templates",5,"papers-templates",{"id":50,"doc_module":9,"doc_module_name":10,"category_name":51,"show_sort_weight":4,"slug":52},158,"General","general-158",{"code":4,"msg":54,"data":55},"ok",{"site_id":56,"language":57,"slug":58,"title":59,"keywords":60,"description":61,"schema_data":62,"social_meta":120,"head_meta":122,"extra_data":124,"updated_unix":126},105,"en","relay-a-high-level-compiler-for-deep-learning","Relay - A High-Level Compiler for Deep Learning","","Deep learning model development increasingly relies on frameworks that write, compile, and optimize networks for different hardware. As model families and device platforms diversify, frameworks face difficult tradeoffs among expressivity, composability, and portability. Relay introduces a new deep learning compiler framework with a functional, statically typed intermediate representation that unifies and generalizes existing IRs. Extension mechanisms enable domain-specific optimizations and a unified compiler targeting CPUs, GPUs, and emerging accelerators without sacrificing performance.",{"@graph":63,"@context":119},[64,80,102],{"@type":65,"itemListElement":66},"BreadcrumbList",[67,71,74,77],{"item":68,"name":69,"@type":70,"position":9},"https://docshare.wps.com","Home","ListItem",{"item":72,"name":10,"@type":70,"position":73},"https://docshare.wps.com/template/",2,{"item":75,"name":11,"@type":70,"position":76},"https://docshare.wps.com/template/presentations/",3,{"item":78,"name":59,"@type":70,"position":79},"https://docshare.wps.com/template/relay-a-high-level-compiler-for-deep-learning/243895/",4,{"url":78,"name":59,"@type":81,"image":82,"author":87,"headline":59,"publisher":90,"fileFormat":93,"inLanguage":57,"description":61,"dateModified":94,"datePublished":95,"encodingFormat":93,"isAccessibleForFree":96,"interactionStatistic":97},"DigitalDocument",{"url":83,"@type":84,"width":85,"height":86},"https://docshare.wps.com/thumbnails/relay-a-high-level-compiler-for-deep-learning/243895.png","ImageObject",442,249,{"name":88,"@type":89},"Levi","Person",{"url":68,"name":91,"@type":92},"DocShare","Organization","application/pdf","2026-10-19","2026-09-12",true,{"@type":98,"interactionType":99,"userInteractionCount":101},"InteractionCounter",{"@type":100},"ViewAction",8,{"@type":103,"mainEntity":104},"FAQPage",[105,111,115],{"name":106,"@type":107,"acceptedAnswer":108},"What problem does Relay aim to solve in deep learning compilation?","Question",{"text":109,"@type":110},"Relay targets the extensibility tradeoffs of existing deep learning IRs, especially expressivity, composability, and portability across diverse models and hardware.","Answer",{"name":112,"@type":107,"acceptedAnswer":113},"How does Relay’s intermediate representation help represent modern deep learning models?",{"text":114,"@type":110},"Relay uses a functional, statically typed tensor-oriented IR with expressive semantics such as control flow, data structures, and first-class functions to represent state-of-the-art models.",{"name":116,"@type":107,"acceptedAnswer":117},"What enables Relay to optimize and target multiple hardware platforms?",{"text":118,"@type":110},"Relay’s extension mechanisms support domain-specific optimizations and enable a unified compiler that can target CPUs, GPUs, and emerging accelerators.","https://schema.org",{"og:url":78,"og:type":121,"og:title":59,"og:site_name":91,"og:description":61},"article",{"robots":123,"canonical":78},"index,follow",{"doc_id":125,"site_id":56},243895,1791748549,{"code":4,"msg":5,"data":128},{"doc_id":125,"user_id":129,"nickname":88,"user_avatar":130,"doc_module":9,"category_id":8,"category_name":11,"doc_title":59,"doc_description":61,"doc_content":131,"file_id":132,"file_url":133,"file_type":134,"file_size":135,"view_count":101,"is_deleted":4,"is_public":9,"is_downloadable":9,"audit_status":9,"page_count":20,"language":136,"language_code":57,"site_id":56,"html_lang":57,"table_of_contents":137,"faqs":138,"seo_title":139,"seo_description":61,"update_tm":140,"read_time":47},7971461740909,"https://ap-avatar.wpscdn.com/davatar_155a257f0dc6eb9ab79c44ca47cae57d","Relay: A High-Level Compiler for Deep Learning  \nJared Roesch, Steven Lyubomirsky, Marisa Kirisame, Logan Weber, Josh Pollock, Luis Vega, Ziheng Jiang,  \nTianqi Chen, Thierry Moreau, and Zachary Tatlock  \n{jroesch, sslyu, jerry96, weberlo, joshpol, vegaluis, ziheng, tqchen, moreau, [ztatlock}@cs.uw.edu](ztatlock}@cs.uw.edu)  \nPaul G. Allen School of Computer Science & Engineering  \nUniversity of Washington  \narXiv : 1904 .08368v2 [ cs .LG] 24 Aug 2019  \nAbstract  \nFrameworks for writing, compiling, and optimizing deep learning (DL) models have recently enabled progress in areas like computer vision and natural language processing. Extending these frameworks to accommodate the rapidly diversifying landscape of DL models and hardware platforms presents challenging tradeoffs between expressivity, composability, and portability. We present Relay, a new compiler framework for DL. Relay's functional, statically typed intermediate representation (IR) uniﬁes and generalizes existing DL IRs to express state-of-the-art models. The introduction of Relay's expressive IR requires careful design of domain-speciﬁc optimizations, addressed via Relay's extension mechanisms. Using these extension mechanisms, Relay supports a uniﬁed compiler that can target a variety of hardware platforms. Our evaluation demonstrates Relay's competitive performance for a broad class of models and devices (CPUs, GPUs, and emerging accelerators). Relay's design demonstrates how a uniﬁed IR can provide expressivity, composability, and portability without compromising performance.  \n1. Introduction  \nDeep learning (DL) has radically transformed domains like computer vision and natural language processing (NLP) [36, 56] . Inspired by these successes, researchers and companies are continually experimenting with increasingly sophisticated DL models and developing specialized hardware backends. DL frameworks for writing, optimizing, and compiling DL models reduce the complexity of these tasks, which in turn accelerates DL research and product development.  \nPopular DL compiler intermediate representations (IRs) offer different tradeoffs between expressivity, composability, and portability [1, 33, 50, 52, 5, 38] . Early frameworks adopted IRs specialized for then-state-of-the-art models and/or emerging hardware accelerators. As a result, nontrivial extensions require patching or even forking frameworks [27, 47, 52, 41, 55, 38, 51] . Such ad hoc extensions can improve expressivity while maintaining backwards compatibility with existing execution mechanisms. However, they are difﬁcult to design, reason about, and implement, often resulting in modiﬁcations that are mutually incompatible.  \nLet us consider a hypothetical scenario that exempliﬁes IR design tensions in DL compilers. Suppose a machine learning engineer wants to write an Android app that uses sentiment analysis to determine the moods of its users. To maintain privacy, the app must run completely on-device, i.e., no work can be ofﬂoaded to the cloud. The engineer decides to use a variant of TreeLSTM, a deep learning model that uses a tree structure [46] . Unfortunately, current frameworks' IRs cannot directly encode trees, so she must use a framework extension like TensorFlow Fold [26] .  \nSuppose that after adapting the model to run on her phone, the out-of-the-box performance of her model on her particular platform is not satisfactory, requiring her to optimize it. She chooses to employ quantization, an optimization that potentially trades accuracy for performance by replacing ﬂoatingpoint datatypes with low-precision ones. Although researchers have developed a variety of quantization strategies, each of which makes use of different bit-widths, rounding modes, and datatypes, our engineer must use a strategy supported by existing frameworks [15, 14, 34] . Unfortunately, frameworks only provide support for a small number of strategies, and supporting new quantization strategies is non-trivial. Each combination of","cbCaiclw0hw830ND","https://ap.wps.com/l/cbCaiclw0hw830ND","pdf",1198572,"English","# Abstract\n# Introduction\n## Extensibility challenges in deep learning IRs\n## Relay's approach and contributions","[{\"question\":\"What problem does Relay aim to solve in deep learning compilation?\",\"answer\":\"Relay targets the extensibility tradeoffs of existing deep learning IRs, especially expressivity, composability, and portability across diverse models and hardware.\"},{\"question\":\"How does Relay’s intermediate representation help represent modern deep learning models?\",\"answer\":\"Relay uses a functional, statically typed tensor-oriented IR with expressive semantics such as control flow, data structures, and first-class functions to represent state-of-the-art models.\"},{\"question\":\"What enables Relay to optimize and target multiple hardware platforms?\",\"answer\":\"Relay’s extension mechanisms support domain-specific optimizations and enable a unified compiler that can target CPUs, GPUs, and emerging accelerators.\"}]","Relay - A High-Level Compiler for Deep Learning | PDF",1789209821]