Keras2c: A library for converting Keras neural networks to real-time compatible C
With the growth of machine learning models and neural networks in measurement and control systems comes the need to deploy these models in a way that is compatible with existing systems. Existing options for deploying neural networks either introduce very high latency, require expensive and time con...
Gespeichert in:
Veröffentlicht in: | Engineering applications of artificial intelligence 2021-04, Vol.100, p.104182, Article 104182 |
---|---|
Hauptverfasser: | , , , |
Format: | Artikel |
Sprache: | eng |
Schlagworte: | |
Online-Zugang: | Volltext |
Tags: |
Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
|
container_end_page | |
---|---|
container_issue | |
container_start_page | 104182 |
container_title | Engineering applications of artificial intelligence |
container_volume | 100 |
creator | Conlin, Rory Erickson, Keith Abbate, Joseph Kolemen, Egemen |
description | With the growth of machine learning models and neural networks in measurement and control systems comes the need to deploy these models in a way that is compatible with existing systems. Existing options for deploying neural networks either introduce very high latency, require expensive and time consuming work to integrate into existing code bases, or only support a very limited subset of model types. We have therefore developed a new method called Keras2c, which is a simple library for converting Keras/TensorFlow neural network models into real-time compatible C code. It supports a wide range of Keras layers and model types including multidimensional convolutions, recurrent layers, multi-input/output models, and shared layers. Keras2c re-implements the core components of Keras/TensorFlow required for predictive forward passes through neural networks in pure C, relying only on standard library functions considered safe for real-time use. The core functionality consists of ∼1500 lines of code, making it lightweight and easy to integrate into existing codebases. Keras2c has been successfully tested in experiments and is currently in use on the plasma control system at the DIII-D National Fusion Facility at General Atomics in San Diego. |
doi_str_mv | 10.1016/j.engappai.2021.104182 |
format | Article |
fullrecord | <record><control><sourceid>elsevier_osti_</sourceid><recordid>TN_cdi_osti_scitechconnect_1809094</recordid><sourceformat>XML</sourceformat><sourcesystem>PC</sourcesystem><els_id>S0952197621000294</els_id><sourcerecordid>S0952197621000294</sourcerecordid><originalsourceid>FETCH-LOGICAL-c387t-826559b154bf68e4876bcc12447a751f4182334547c36bd3b7e8464f38c1143a3</originalsourceid><addsrcrecordid>eNqFUF1LwzAUDaLgnP4FCb53Jk2apD45hl84EEGfQ5rezsyuLUmc-O9NrT77dOByPu45CJ1TsqCEisvtArqNGQbjFjnJaTpyqvIDNKNKskxIUR6iGSmLPKOlFMfoJIQtIYQpLmbo-RG8Cbm9wkvcusob_4Wb3mPbd3vw0XUb_MPAHXx40yaIn71_Dzj22INps-h2kNi7wURXtYBXp-ioMW2As1-co9fbm5fVfbZ-untYLdeZZUrGTOWiKMqKFrxqhAKupKispTnn0siCNmMHxnjBpWWiqlklIT3MG6YspZwZNkcXk28fotPBugj2Lb3dgY2aKlKSkieSmEjW9yF4aPTg3S6V1JTocT291X_r6XE9Pa2XhNeTEFKFvQM_JkBnoXZ-DKh795_FN8t3eiU</addsrcrecordid><sourcetype>Open Access Repository</sourcetype><iscdi>true</iscdi><recordtype>article</recordtype></control><display><type>article</type><title>Keras2c: A library for converting Keras neural networks to real-time compatible C</title><source>Access via ScienceDirect (Elsevier)</source><creator>Conlin, Rory ; Erickson, Keith ; Abbate, Joseph ; Kolemen, Egemen</creator><creatorcontrib>Conlin, Rory ; Erickson, Keith ; Abbate, Joseph ; Kolemen, Egemen ; Princeton Plasma Physics Lab. (PPPL), Princeton, NJ (United States)</creatorcontrib><description>With the growth of machine learning models and neural networks in measurement and control systems comes the need to deploy these models in a way that is compatible with existing systems. Existing options for deploying neural networks either introduce very high latency, require expensive and time consuming work to integrate into existing code bases, or only support a very limited subset of model types. We have therefore developed a new method called Keras2c, which is a simple library for converting Keras/TensorFlow neural network models into real-time compatible C code. It supports a wide range of Keras layers and model types including multidimensional convolutions, recurrent layers, multi-input/output models, and shared layers. Keras2c re-implements the core components of Keras/TensorFlow required for predictive forward passes through neural networks in pure C, relying only on standard library functions considered safe for real-time use. The core functionality consists of ∼1500 lines of code, making it lightweight and easy to integrate into existing codebases. Keras2c has been successfully tested in experiments and is currently in use on the plasma control system at the DIII-D National Fusion Facility at General Atomics in San Diego.</description><identifier>ISSN: 0952-1976</identifier><identifier>EISSN: 1873-6769</identifier><identifier>DOI: 10.1016/j.engappai.2021.104182</identifier><language>eng</language><publisher>United States: Elsevier Ltd</publisher><subject>70 PLASMA PHYSICS AND FUSION TECHNOLOGY ; C Code ; Control systems ; Keras ; MATHEMATICS AND COMPUTING ; Neural networks ; Real-time ; Software</subject><ispartof>Engineering applications of artificial intelligence, 2021-04, Vol.100, p.104182, Article 104182</ispartof><rights>2021 Elsevier Ltd</rights><lds50>peer_reviewed</lds50><oa>free_for_read</oa><woscitedreferencessubscribed>false</woscitedreferencessubscribed><citedby>FETCH-LOGICAL-c387t-826559b154bf68e4876bcc12447a751f4182334547c36bd3b7e8464f38c1143a3</citedby><cites>FETCH-LOGICAL-c387t-826559b154bf68e4876bcc12447a751f4182334547c36bd3b7e8464f38c1143a3</cites><orcidid>0000-0002-5463-6552 ; 0000-0003-4212-3247 ; 0000-0003-1216-8719 ; 0000000312168719 ; 0000000342123247 ; 0000000254636552</orcidid></display><links><openurl>$$Topenurl_article</openurl><openurlfulltext>$$Topenurlfull_article</openurlfulltext><thumbnail>$$Tsyndetics_thumb_exl</thumbnail><linktohtml>$$Uhttps://dx.doi.org/10.1016/j.engappai.2021.104182$$EHTML$$P50$$Gelsevier$$H</linktohtml><link.rule.ids>230,314,780,784,885,3550,27924,27925,45995</link.rule.ids><backlink>$$Uhttps://www.osti.gov/servlets/purl/1809094$$D View this record in Osti.gov$$Hfree_for_read</backlink></links><search><creatorcontrib>Conlin, Rory</creatorcontrib><creatorcontrib>Erickson, Keith</creatorcontrib><creatorcontrib>Abbate, Joseph</creatorcontrib><creatorcontrib>Kolemen, Egemen</creatorcontrib><creatorcontrib>Princeton Plasma Physics Lab. (PPPL), Princeton, NJ (United States)</creatorcontrib><title>Keras2c: A library for converting Keras neural networks to real-time compatible C</title><title>Engineering applications of artificial intelligence</title><description>With the growth of machine learning models and neural networks in measurement and control systems comes the need to deploy these models in a way that is compatible with existing systems. Existing options for deploying neural networks either introduce very high latency, require expensive and time consuming work to integrate into existing code bases, or only support a very limited subset of model types. We have therefore developed a new method called Keras2c, which is a simple library for converting Keras/TensorFlow neural network models into real-time compatible C code. It supports a wide range of Keras layers and model types including multidimensional convolutions, recurrent layers, multi-input/output models, and shared layers. Keras2c re-implements the core components of Keras/TensorFlow required for predictive forward passes through neural networks in pure C, relying only on standard library functions considered safe for real-time use. The core functionality consists of ∼1500 lines of code, making it lightweight and easy to integrate into existing codebases. Keras2c has been successfully tested in experiments and is currently in use on the plasma control system at the DIII-D National Fusion Facility at General Atomics in San Diego.</description><subject>70 PLASMA PHYSICS AND FUSION TECHNOLOGY</subject><subject>C Code</subject><subject>Control systems</subject><subject>Keras</subject><subject>MATHEMATICS AND COMPUTING</subject><subject>Neural networks</subject><subject>Real-time</subject><subject>Software</subject><issn>0952-1976</issn><issn>1873-6769</issn><fulltext>true</fulltext><rsrctype>article</rsrctype><creationdate>2021</creationdate><recordtype>article</recordtype><recordid>eNqFUF1LwzAUDaLgnP4FCb53Jk2apD45hl84EEGfQ5rezsyuLUmc-O9NrT77dOByPu45CJ1TsqCEisvtArqNGQbjFjnJaTpyqvIDNKNKskxIUR6iGSmLPKOlFMfoJIQtIYQpLmbo-RG8Cbm9wkvcusob_4Wb3mPbd3vw0XUb_MPAHXx40yaIn71_Dzj22INps-h2kNi7wURXtYBXp-ioMW2As1-co9fbm5fVfbZ-untYLdeZZUrGTOWiKMqKFrxqhAKupKispTnn0siCNmMHxnjBpWWiqlklIT3MG6YspZwZNkcXk28fotPBugj2Lb3dgY2aKlKSkieSmEjW9yF4aPTg3S6V1JTocT291X_r6XE9Pa2XhNeTEFKFvQM_JkBnoXZ-DKh795_FN8t3eiU</recordid><startdate>20210401</startdate><enddate>20210401</enddate><creator>Conlin, Rory</creator><creator>Erickson, Keith</creator><creator>Abbate, Joseph</creator><creator>Kolemen, Egemen</creator><general>Elsevier Ltd</general><general>Elsevier</general><scope>AAYXX</scope><scope>CITATION</scope><scope>OIOZB</scope><scope>OTOTI</scope><orcidid>https://orcid.org/0000-0002-5463-6552</orcidid><orcidid>https://orcid.org/0000-0003-4212-3247</orcidid><orcidid>https://orcid.org/0000-0003-1216-8719</orcidid><orcidid>https://orcid.org/0000000312168719</orcidid><orcidid>https://orcid.org/0000000342123247</orcidid><orcidid>https://orcid.org/0000000254636552</orcidid></search><sort><creationdate>20210401</creationdate><title>Keras2c: A library for converting Keras neural networks to real-time compatible C</title><author>Conlin, Rory ; Erickson, Keith ; Abbate, Joseph ; Kolemen, Egemen</author></sort><facets><frbrtype>5</frbrtype><frbrgroupid>cdi_FETCH-LOGICAL-c387t-826559b154bf68e4876bcc12447a751f4182334547c36bd3b7e8464f38c1143a3</frbrgroupid><rsrctype>articles</rsrctype><prefilter>articles</prefilter><language>eng</language><creationdate>2021</creationdate><topic>70 PLASMA PHYSICS AND FUSION TECHNOLOGY</topic><topic>C Code</topic><topic>Control systems</topic><topic>Keras</topic><topic>MATHEMATICS AND COMPUTING</topic><topic>Neural networks</topic><topic>Real-time</topic><topic>Software</topic><toplevel>peer_reviewed</toplevel><toplevel>online_resources</toplevel><creatorcontrib>Conlin, Rory</creatorcontrib><creatorcontrib>Erickson, Keith</creatorcontrib><creatorcontrib>Abbate, Joseph</creatorcontrib><creatorcontrib>Kolemen, Egemen</creatorcontrib><creatorcontrib>Princeton Plasma Physics Lab. (PPPL), Princeton, NJ (United States)</creatorcontrib><collection>CrossRef</collection><collection>OSTI.GOV - Hybrid</collection><collection>OSTI.GOV</collection><jtitle>Engineering applications of artificial intelligence</jtitle></facets><delivery><delcategory>Remote Search Resource</delcategory><fulltext>fulltext</fulltext></delivery><addata><au>Conlin, Rory</au><au>Erickson, Keith</au><au>Abbate, Joseph</au><au>Kolemen, Egemen</au><aucorp>Princeton Plasma Physics Lab. (PPPL), Princeton, NJ (United States)</aucorp><format>journal</format><genre>article</genre><ristype>JOUR</ristype><atitle>Keras2c: A library for converting Keras neural networks to real-time compatible C</atitle><jtitle>Engineering applications of artificial intelligence</jtitle><date>2021-04-01</date><risdate>2021</risdate><volume>100</volume><spage>104182</spage><pages>104182-</pages><artnum>104182</artnum><issn>0952-1976</issn><eissn>1873-6769</eissn><abstract>With the growth of machine learning models and neural networks in measurement and control systems comes the need to deploy these models in a way that is compatible with existing systems. Existing options for deploying neural networks either introduce very high latency, require expensive and time consuming work to integrate into existing code bases, or only support a very limited subset of model types. We have therefore developed a new method called Keras2c, which is a simple library for converting Keras/TensorFlow neural network models into real-time compatible C code. It supports a wide range of Keras layers and model types including multidimensional convolutions, recurrent layers, multi-input/output models, and shared layers. Keras2c re-implements the core components of Keras/TensorFlow required for predictive forward passes through neural networks in pure C, relying only on standard library functions considered safe for real-time use. The core functionality consists of ∼1500 lines of code, making it lightweight and easy to integrate into existing codebases. Keras2c has been successfully tested in experiments and is currently in use on the plasma control system at the DIII-D National Fusion Facility at General Atomics in San Diego.</abstract><cop>United States</cop><pub>Elsevier Ltd</pub><doi>10.1016/j.engappai.2021.104182</doi><orcidid>https://orcid.org/0000-0002-5463-6552</orcidid><orcidid>https://orcid.org/0000-0003-4212-3247</orcidid><orcidid>https://orcid.org/0000-0003-1216-8719</orcidid><orcidid>https://orcid.org/0000000312168719</orcidid><orcidid>https://orcid.org/0000000342123247</orcidid><orcidid>https://orcid.org/0000000254636552</orcidid><oa>free_for_read</oa></addata></record> |
fulltext | fulltext |
identifier | ISSN: 0952-1976 |
ispartof | Engineering applications of artificial intelligence, 2021-04, Vol.100, p.104182, Article 104182 |
issn | 0952-1976 1873-6769 |
language | eng |
recordid | cdi_osti_scitechconnect_1809094 |
source | Access via ScienceDirect (Elsevier) |
subjects | 70 PLASMA PHYSICS AND FUSION TECHNOLOGY C Code Control systems Keras MATHEMATICS AND COMPUTING Neural networks Real-time Software |
title | Keras2c: A library for converting Keras neural networks to real-time compatible C |
url | https://sfx.bib-bvb.de/sfx_tum?ctx_ver=Z39.88-2004&ctx_enc=info:ofi/enc:UTF-8&ctx_tim=2025-01-03T22%3A18%3A59IST&url_ver=Z39.88-2004&url_ctx_fmt=infofi/fmt:kev:mtx:ctx&rfr_id=info:sid/primo.exlibrisgroup.com:primo3-Article-elsevier_osti_&rft_val_fmt=info:ofi/fmt:kev:mtx:journal&rft.genre=article&rft.atitle=Keras2c:%20A%20library%20for%20converting%20Keras%20neural%20networks%20to%20real-time%20compatible%20C&rft.jtitle=Engineering%20applications%20of%20artificial%20intelligence&rft.au=Conlin,%20Rory&rft.aucorp=Princeton%20Plasma%20Physics%20Lab.%20(PPPL),%20Princeton,%20NJ%20(United%20States)&rft.date=2021-04-01&rft.volume=100&rft.spage=104182&rft.pages=104182-&rft.artnum=104182&rft.issn=0952-1976&rft.eissn=1873-6769&rft_id=info:doi/10.1016/j.engappai.2021.104182&rft_dat=%3Celsevier_osti_%3ES0952197621000294%3C/elsevier_osti_%3E%3Curl%3E%3C/url%3E&disable_directlink=true&sfx.directlink=off&sfx.report_link=0&rft_id=info:oai/&rft_id=info:pmid/&rft_els_id=S0952197621000294&rfr_iscdi=true |