![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
2011
Diff: main.cpp
- Revision:
- 181:2a8b5f3274be
- Parent:
- 180:02be1711ee0b
- Child:
- 182:11105b2528dc
diff -r 02be1711ee0b -r 2a8b5f3274be main.cpp --- a/main.cpp Tue Dec 15 00:19:25 2020 +0000 +++ b/main.cpp Tue Dec 15 01:36:28 2020 +0000 @@ -1,4 +1,4 @@ -//201215-1 +//201215-2 #include "mbed.h" #include "FastPWM.h" #include "INIT_HW.h" @@ -198,72 +198,72 @@ float input_NN[num_input] = { 0.0f }; const float h1[num_input][16] = { - {-1.2747926712036133f,0.8866214156150818f,0.12903714179992676f,0.1954565942287445f,-1.0775936841964722f,1.0385150909423828f,-0.17472904920578003f,1.2043118476867676f,-1.0528837442398071f,0.16233131289482117f,-0.23384490609169006f,-0.9654906988143921f,-0.26406702399253845f,0.45232266187667847f,-0.2571594715118408f,-1.4159953594207764f}, -{-0.9898881912231445f,0.5978912115097046f,-0.3927857577800751f,-0.10504250973463058f,-0.7563983798027039f,0.5094512104988098f,-0.4054011106491089f,1.1116833686828613f,-0.4969346523284912f,0.41541942954063416f,-0.2706531882286072f,-0.5124550461769104f,0.23551900684833527f,-0.0996662825345993f,-0.20967772603034973f,-0.7428423166275024f}, -{-0.6586143970489502f,0.2526506185531616f,0.36391180753707886f,-0.44479653239250183f,-0.12272748351097107f,0.29624244570732117f,0.2872133255004883f,1.3258525133132935f,-0.23638273775577545f,0.4212562143802643f,-0.34454482793807983f,-0.2005833387374878f,-0.002771292580291629f,0.36579757928848267f,0.05590221285820007f,-0.5957719087600708f}, -{-0.17435620725154877f,-0.34709569811820984f,0.39742106199264526f,0.23025836050510406f,0.31759893894195557f,-0.48005908727645874f,-0.11584559082984924f,1.618665337562561f,0.2961588501930237f,0.5570516586303711f,0.09927701205015182f,0.5736197233200073f,-0.1649491935968399f,0.2608615458011627f,-0.2961459457874298f,0.12930260598659515f}, -{0.7618234157562256f,-0.5603615045547485f,-0.0051451027393341064f,0.19888998568058014f,0.7619378566741943f,-0.606192409992218f,0.1294034719467163f,1.2932729721069336f,0.6787902116775513f,0.37368881702423096f,0.3512172996997833f,0.7094911336898804f,-0.06857605278491974f,0.38823315501213074f,-0.3865056037902832f,0.2566696107387543f}, -{1.4753985404968262f,-1.5749534368515015f,0.21773302555084229f,0.24970105290412903f,1.438091516494751f,-1.3410722017288208f,0.16514194011688232f,1.0581666231155396f,1.1054584980010986f,0.38477128744125366f,-0.2443389892578125f,1.3622721433639526f,-0.26528480648994446f,0.5235674381256104f,-0.4132833778858185f,0.7429633736610413f}, -{-0.1381414830684662f,0.32296326756477356f,-0.2501986622810364f,-0.6822501420974731f,-0.6484224200248718f,0.3961770534515381f,0.06014183163642883f,-1.9562623500823975f,0.14606209099292755f,-0.30881643295288086f,0.15261518955230713f,-0.10579380393028259f,-0.17127792537212372f,-0.04263466224074364f,-0.15618428587913513f,-0.033108823001384735f}, -{0.10407276451587677f,-0.17438587546348572f,-0.26619744300842285f,-0.10469675064086914f,-0.40487462282180786f,-0.18597395718097687f,-0.17925891280174255f,-1.6444649696350098f,-0.010120101273059845f,-0.23186346888542175f,0.10695241391658783f,-0.2862721085548401f,0.37284889817237854f,-0.23048385977745056f,0.04303058981895447f,0.28026261925697327f}, -{0.30488404631614685f,0.349077045917511f,0.10248100757598877f,-0.5642396211624146f,-0.1891011893749237f,0.013860803097486496f,-0.07246989011764526f,-1.5340245962142944f,-0.27067628502845764f,0.018050722777843475f,-0.2956160306930542f,0.1977348029613495f,0.23040179908275604f,-0.1158660352230072f,-0.30555272102355957f,0.28618332743644714f}, -{0.10323967039585114f,-0.2507255971431732f,0.18462657928466797f,-0.2965702414512634f,0.1769070029258728f,0.11360282450914383f,-0.2990540862083435f,-1.0921586751937866f,0.046090397983789444f,-0.784417986869812f,-0.0066079325042665005f,-0.54339599609375f,0.3733484447002411f,-0.531656801700592f,0.3484981060028076f,0.09402719140052795f}, -{0.5437068939208984f,0.12157454341650009f,0.37182438373565674f,0.10810510069131851f,0.017796188592910767f,-0.06259164214134216f,-0.20339298248291016f,-0.9021218419075012f,-0.41913050413131714f,-0.2746804654598236f,0.35008612275123596f,-0.3781108260154724f,-0.06551998108625412f,-0.29703405499458313f,0.26688337326049805f,-0.31737634539604187f}, -{-0.24231690168380737f,-0.3807550072669983f,-0.40320003032684326f,-0.135234072804451f,0.13232052326202393f,-0.12746357917785645f,0.1533789038658142f,-0.46155455708503723f,-0.13511259853839874f,-0.08907300978899002f,-0.41252845525741577f,0.06504666805267334f,0.14570680260658264f,-0.2993526756763458f,0.10493969917297363f,-0.09489677101373672f}, -{0.0872870460152626f,-0.23291699588298798f,0.19847965240478516f,0.02823140099644661f,0.37074705958366394f,0.040752362459897995f,-0.2404318004846573f,-0.586179256439209f,-0.11466588079929352f,-0.4817463457584381f,-0.10735541582107544f,-0.3017888367176056f,0.09303940832614899f,-0.2488478273153305f,-0.22268100082874298f,-0.37364980578422546f}, -{-0.051991432905197144f,-0.12674333155155182f,0.4127817749977112f,-0.19834384322166443f,-0.20412969589233398f,-0.3441471755504608f,-0.32001304626464844f,-0.9517143368721008f,-0.07627648115158081f,-0.5058509111404419f,-0.1932433545589447f,-0.2879234254360199f,-0.31180211901664734f,-0.30530187487602234f,0.0479682981967926f,0.06262191385030746f}, -{0.10936000198125839f,0.09897122532129288f,0.20282304286956787f,-0.03914237394928932f,0.2795373797416687f,-0.11763463914394379f,0.04202890396118164f,-0.4100075960159302f,0.23455728590488434f,-0.19801537692546844f,-0.27762651443481445f,-0.6615355014801025f,0.10450632870197296f,-0.29707828164100647f,0.0668090283870697f,-0.0025110316928476095f}, -{-0.07633624225854874f,-0.29659169912338257f,-0.40439701080322266f,-0.18466457724571228f,-0.17516319453716278f,-0.013456307351589203f,-0.15568238496780396f,-0.6675025224685669f,0.1871490478515625f,-0.28267568349838257f,-0.4720761179924011f,-0.25658828020095825f,-0.2701036036014557f,-0.2391444593667984f,-0.08245879411697388f,0.0812353640794754f}, -{-0.1064588725566864f,-0.12016399204730988f,0.16706281900405884f,0.007519781589508057f,-0.017588406801223755f,-0.26146987080574036f,-0.041414469480514526f,-0.6730034947395325f,-0.06899238377809525f,-0.18613839149475098f,-0.3516925573348999f,0.1851750761270523f,0.11302956193685532f,0.11544660478830338f,0.29427415132522583f,-0.08377157896757126f}, + {0.08059316128492355f,0.6838099956512451f,0.12903714179992676f,0.4585042893886566f,-0.9330493211746216f,0.7820676565170288f,-0.17472904920578003f,0.5929365158081055f,-0.8172562718391418f,0.05025840923190117f,-0.22792614996433258f,-0.5645073056221008f,-0.26447197794914246f,0.34380945563316345f,-0.2571594715118408f,-1.4536206722259521f}, +{-0.06843511015176773f,0.4414166808128357f,-0.3927857577800751f,0.15489579737186432f,-0.6540799736976624f,0.29724636673927307f,-0.4054011106491089f,0.18746623396873474f,-0.3084494471549988f,0.3044531047344208f,-0.26472508907318115f,-0.2922133505344391f,0.23510316014289856f,-0.20713169872760773f,-0.20967772603034973f,-0.8509552478790283f}, +{-0.1643858551979065f,0.1446225345134735f,0.36391180753707886f,-0.18808580935001373f,-0.06454475224018097f,0.13017675280570984f,0.2872133255004883f,0.09860920906066895f,-0.09649200737476349f,0.3113968074321747f,-0.3386077284812927f,-0.15769506990909576f,-0.0031952743884176016f,0.25935444235801697f,0.05590221285820007f,-0.776764452457428f}, +{-0.11569413542747498f,-0.4068849980831146f,0.39742106199264526f,0.48360368609428406f,0.33205947279930115f,-0.6003721356391907f,-0.11584559082984924f,0.08130582422018051f,0.3878571391105652f,0.4483059346675873f,0.105223149061203f,0.4361564815044403f,-0.16538025438785553f,0.15540266036987305f,-0.2961459457874298f,-0.12508058547973633f}, +{0.35479822754859924f,-0.5773555636405945f,-0.0051451027393341064f,0.4487404525279999f,0.7382810711860657f,-0.6862490773200989f,0.1294034719467163f,-0.5869422554969788f,0.7271066308021545f,0.2660955786705017f,0.3571736812591553f,0.3810521066188812f,-0.06901402026414871f,0.28377822041511536f,-0.3865056037902832f,-0.06671316921710968f}, +{0.5522244572639465f,-1.554945468902588f,0.21773302555084229f,0.49587738513946533f,1.3824152946472168f,-1.386751651763916f,0.16514194011688232f,-1.2176135778427124f,1.1150975227355957f,0.278342604637146f,-0.23837466537952423f,0.8222489356994629f,-0.2657281160354614f,0.42007002234458923f,-0.4132833778858185f,0.35377174615859985f}, +{-0.5814220309257507f,0.33646413683891296f,-0.2501986622810364f,-1.3750731945037842f,-0.8147061467170715f,0.731468141078949f,0.06014183163642883f,0.08090995997190475f,0.08669452369213104f,-0.2917703688144684f,0.15766414999961853f,-0.6732032895088196f,-0.17225678265094757f,0.02596128359436989f,-0.15618428587913513f,1.4006550312042236f}, +{-0.34514936804771423f,-0.049776703119277954f,-0.26619744300842285f,-0.26967060565948486f,-0.5994526147842407f,0.04246774688363075f,-0.17925891280174255f,-0.3342619836330414f,-0.16641566157341003f,-0.04858541488647461f,0.11226584017276764f,-0.6202855706214905f,0.3721274733543396f,0.002934061223641038f,0.04303058981895447f,0.3797107934951782f}, +{-0.16485169529914856f,0.3687754273414612f,0.10248100757598877f,-0.7319263219833374f,-0.25461676716804504f,0.10218558460474014f,-0.07246989011764526f,-0.5123102068901062f,-0.2873164117336273f,0.19666269421577454f,-0.29032474756240845f,-0.08155026286840439f,0.22964464128017426f,0.10404440015554428f,-0.30555272102355957f,0.5234727263450623f}, +{-0.3842744827270508f,-0.12795858085155487f,0.18462657928466797f,-0.4709790349006653f,0.02566634863615036f,0.2784605026245117f,-0.2990540862083435f,-0.11813750863075256f,-0.0513276606798172f,-0.6121172904968262f,-0.001270004897378385f,-0.9109545946121216f,0.3726291358470917f,-0.32367831468582153f,0.3484981060028076f,0.23494087159633636f}, +{0.1562412679195404f,0.060033056885004044f,0.37182438373565674f,-0.07121864706277847f,0.06713905185461044f,-0.10511155426502228f,-0.20339298248291016f,-0.13800114393234253f,-0.3202115297317505f,-0.10405322909355164f,0.3553784191608429f,-0.5518741011619568f,-0.06626003235578537f,-0.09551427513360977f,0.26688337326049805f,0.018239976838231087f}, +{-0.5941224694252014f,-0.23777620494365692f,-0.40320003032684326f,-0.31705784797668457f,-0.015506955794990063f,0.017545536160469055f,0.1533789038658142f,0.45822274684906006f,-0.22824068367481232f,0.07836488634347916f,-0.4071876108646393f,-0.2756684124469757f,0.14495661854743958f,-0.10264411568641663f,0.10493969917297363f,-0.0005824507097713649f}, +{-0.25569793581962585f,-0.19621911644935608f,0.19847965240478516f,-0.15797235071659088f,0.345569908618927f,0.06000465527176857f,-0.2404318004846573f,0.08413219451904297f,-0.08944720029830933f,-0.31927502155303955f,-0.1020159125328064f,-0.5156699419021606f,0.09228844195604324f,-0.05963599309325218f,-0.22268100082874298f,-0.1811557114124298f}, +{-0.3295969069004059f,0.060612753033638f,0.4127817749977112f,-0.3861438035964966f,-0.36917024850845337f,-0.1909361481666565f,-0.32001304626464844f,-0.21803538501262665f,-0.18387441337108612f,-0.3484867215156555f,-0.1878705471754074f,-0.5784162282943726f,-0.3125506341457367f,-0.12499208748340607f,0.0479682981967926f,0.086069755256176f}, +{0.016594847664237022f,0.20813298225402832f,0.20282304286956787f,-0.22358374297618866f,0.19735734164714813f,-0.052274011075496674f,0.04202890396118164f,0.3879692852497101f,0.20809297263622284f,-0.04033491015434265f,-0.2722669839859009f,-0.8398635983467102f,0.1037883311510086f,-0.11886490881443024f,0.0668090283870697f,0.07692024856805801f}, +{-0.18911008536815643f,-0.15539002418518066f,-0.40439701080322266f,-0.3687029480934143f,-0.28031474351882935f,0.07188887894153595f,-0.15568238496780396f,0.07451104372739792f,0.1388389766216278f,-0.12777215242385864f,-0.4666607081890106f,-0.45405423641204834f,-0.2708668112754822f,-0.06570909172296524f,-0.08245879411697388f,0.12069441378116608f}, +{-0.2098730206489563f,0.0005108541809022427f,0.16706281900405884f,-0.17491242289543152f,-0.09242749214172363f,-0.21054498851299286f,-0.041414469480514526f,0.07390790432691574f,-0.08338413387537003f,-0.0332307405769825f,-0.34629935026168823f,0.014119500294327736f,0.11230245977640152f,0.28523188829421997f,0.29427415132522583f,-0.015851952135562897f}, }; const float h2[16][16] = { - {-0.48791801929473877f,0.6882094144821167f,-0.06966331601142883f,0.004637989681214094f,-0.21907491981983185f,0.06930378824472427f,0.07693875581026077f,0.036887940019369125f,-0.43008196353912354f,-0.1415480375289917f,-0.5828585028648376f,-0.32945704460144043f,-0.008075037971138954f,-1.5241717100143433f,-0.2089289128780365f,-0.7718607783317566f}, -{0.04395662993192673f,-1.437508463859558f,0.057057321071624756f,-0.12063508480787277f,-0.35503754019737244f,-0.8848034143447876f,-0.41094034910202026f,-0.34160447120666504f,-0.33757925033569336f,0.2895788848400116f,-1.4832773208618164f,-0.636014461517334f,0.19798265397548676f,0.9338656067848206f,-0.30581197142601013f,-0.20769454538822174f}, + {-0.05400395393371582f,-0.22951123118400574f,-0.06966331601142883f,-0.10873724520206451f,-0.21907491981983185f,0.39131346344947815f,0.2356909215450287f,-0.008777995593845844f,-0.43008196353912354f,-0.1415480375289917f,0.06827273964881897f,-0.13159732520580292f,0.12968102097511292f,0.07670671492815018f,-0.0314212366938591f,-0.21922312676906586f}, +{0.9290517568588257f,-0.9921830296516418f,0.057057321071624756f,-0.20214742422103882f,-0.35503754019737244f,-0.46737948060035706f,-0.6570143103599548f,-0.7452677488327026f,-0.4557425379753113f,0.2895788848400116f,-0.9277383685112f,-0.5550819635391235f,0.33698758482933044f,0.45979171991348267f,-0.4884485900402069f,-2.1815340518951416f}, {-0.22745239734649658f,0.003037691116333008f,-0.061119019985198975f,0.35696902871131897f,0.05568113923072815f,0.011741191148757935f,-0.20225946605205536f,-0.08465918898582458f,0.3489862382411957f,0.0687277615070343f,0.31964078545570374f,0.3004753887653351f,0.36063823103904724f,-0.42892736196517944f,0.08652284741401672f,0.027493387460708618f}, -{0.07395064830780029f,-0.270321786403656f,-0.2894435524940491f,0.4473000168800354f,0.08946844935417175f,0.2554236948490143f,-0.23805393278598785f,0.35016298294067383f,0.26211628317832947f,0.2953031361103058f,0.2565111219882965f,0.38108423352241516f,-0.404754102230072f,-0.24778899550437927f,0.17891016602516174f,0.042497243732213974f}, -{-0.5532359480857849f,0.39376264810562134f,-0.25313520431518555f,0.1859339028596878f,0.036378175020217896f,0.017076050862669945f,-0.39785856008529663f,-0.1502944529056549f,-0.024399548768997192f,-0.39465832710266113f,-0.5060166716575623f,-0.6321212649345398f,-0.03745249658823013f,-0.5525979995727539f,-0.34934699535369873f,-0.5389713644981384f}, -{0.10334087163209915f,-0.846465528011322f,-0.3519742488861084f,0.1501602679491043f,-0.3015052080154419f,-0.7330282330513f,-0.4977985620498657f,-0.08387657254934311f,-0.23047015070915222f,0.3579089343547821f,-1.1615582704544067f,-0.32632172107696533f,-0.348274827003479f,0.9656168818473816f,0.16907939314842224f,-0.29072293639183044f}, +{-0.9565858244895935f,0.2860046923160553f,-0.2894435524940491f,0.42715516686439514f,0.08946844935417175f,0.7670595645904541f,-0.23805393278598785f,0.5817441344261169f,0.10972626507282257f,0.2953031361103058f,0.6121941208839417f,0.38107964396476746f,-0.404754102230072f,-0.8919617533683777f,0.17776212096214294f,-0.5585567951202393f}, +{-0.37661007046699524f,0.5473698377609253f,-0.25313520431518555f,0.14784954488277435f,0.036378175020217896f,-0.0028403012547641993f,-0.28802114725112915f,-0.13930337131023407f,-0.17753788828849792f,-0.39465832710266113f,-0.4082062542438507f,-0.6109246611595154f,0.10077962279319763f,-0.9768962860107422f,-0.33441993594169617f,-0.5207529664039612f}, +{1.1110279560089111f,-0.5293550491333008f,-0.3519742488861084f,0.03246952220797539f,-0.3015052080154419f,-0.9451113939285278f,-0.7369685769081116f,-0.5327492952346802f,-0.3814910650253296f,0.3579089343547821f,-0.48080307245254517f,-0.18460115790367126f,-0.20959392189979553f,0.8797638416290283f,0.1426876187324524f,-1.7244540452957153f}, {-0.1828227937221527f,-0.02554568648338318f,-0.3260969817638397f,0.08422836661338806f,-0.38453540205955505f,-0.25432005524635315f,0.285016268491745f,0.12387624382972717f,-0.0982072651386261f,0.13111665844917297f,-0.03692615032196045f,-0.32796353101730347f,-0.21546880900859833f,0.049302369356155396f,-0.27088475227355957f,-0.4124959409236908f}, -{0.1127469465136528f,0.23652486503124237f,0.33083590865135193f,-0.08112672716379166f,-0.14358049631118774f,-0.01184199471026659f,-0.24124479293823242f,-0.33522558212280273f,0.2600560486316681f,-0.37898191809654236f,0.9399498701095581f,-0.3190816640853882f,-0.31673234701156616f,-0.6848183870315552f,-0.09104667603969574f,-1.2106350660324097f}, -{-0.5105041861534119f,0.2105989009141922f,-0.11379697918891907f,-0.07779005914926529f,0.041274964809417725f,-0.7625871300697327f,-0.26743561029434204f,-0.05350113660097122f,0.06103590130805969f,-0.38046833872795105f,-0.3830336034297943f,-0.5462559461593628f,-0.5090579390525818f,-0.52454674243927f,-0.3531858026981354f,-0.3511944115161896f}, -{0.6011585593223572f,1.278187870979309f,-0.13502129912376404f,1.4583508968353271f,0.12987366318702698f,0.8150514364242554f,0.2711336314678192f,-0.3632148504257202f,-0.13619378209114075f,0.16938945651054382f,1.0110341310501099f,0.3686404824256897f,0.3811538517475128f,-1.2410987615585327f,-0.6160189509391785f,-0.767787754535675f}, -{-0.28924494981765747f,0.015288889408111572f,0.0457797646522522f,-0.35267168283462524f,-0.03321319818496704f,-0.40105175971984863f,0.17873415350914001f,-0.20421427488327026f,-0.050184011459350586f,0.12480869889259338f,-0.1917455494403839f,0.3545852601528168f,-0.3647043704986572f,0.39774590730667114f,-0.41770800948143005f,-0.26388612389564514f}, -{0.10732869058847427f,0.20420478284358978f,0.3954955041408539f,0.14591671526432037f,0.0033026933670043945f,-0.09065821766853333f,-0.3228403925895691f,-0.1903812736272812f,0.3487861454486847f,-0.32520344853401184f,-0.0845566838979721f,-0.4106420576572418f,-0.05643285810947418f,-0.5659568309783936f,0.2659776210784912f,0.07771870493888855f}, -{-0.268172949552536f,-0.20979687571525574f,-0.15798500180244446f,0.3764939606189728f,-0.37393757700920105f,0.36793282628059387f,0.11292675137519836f,-0.2947862446308136f,-0.3764709532260895f,0.2424570620059967f,-0.10847131162881851f,-0.2837170362472534f,0.41839322447776794f,-0.01855253241956234f,-0.12935252487659454f,0.11022517085075378f}, -{0.1594800055027008f,1.2708461284637451f,-0.2018718123435974f,1.449450135231018f,0.07545611262321472f,0.7168979048728943f,-0.11297860741615295f,-0.21416273713111877f,-0.24509364366531372f,0.19522181153297424f,0.9486110210418701f,-0.28593289852142334f,-0.16718891263008118f,-0.6753664016723633f,-0.7633404731750488f,-0.614047646522522f}, +{0.16531096398830414f,0.04966016113758087f,0.33083590865135193f,-0.4425032436847687f,-0.14358049631118774f,-0.9807811379432678f,-0.3880852460861206f,-0.8615179061889648f,0.10716517269611359f,-0.37898191809654236f,-0.051661401987075806f,-0.46622318029403687f,-0.31673234701156616f,-0.02230437658727169f,-0.09939872473478317f,-0.9386699795722961f}, +{0.02883215993642807f,0.2520259916782379f,-0.11379697918891907f,-0.10356875509023666f,0.041274964809417725f,-0.6097686290740967f,-0.1441202163696289f,-0.02050759643316269f,-0.09214042872190475f,-0.38046833872795105f,-0.1502196490764618f,-0.5078089833259583f,-0.37024784088134766f,-0.762536883354187f,-0.4466892182826996f,-0.5266298055648804f}, +{-0.3985212743282318f,0.6033523082733154f,-0.13502129912376404f,0.49556124210357666f,0.12987366318702698f,0.6040406227111816f,0.2711336314678192f,-0.3632148504257202f,-0.13619378209114075f,0.16938945651054382f,0.7007452845573425f,0.36862730979919434f,0.3811538517475128f,-0.684626042842865f,-0.38069233298301697f,-0.02814050391316414f}, +{-0.29173463582992554f,0.016833867877721786f,0.0457797646522522f,-0.3521595597267151f,-0.03321319818496704f,-0.399382084608078f,0.17873415350914001f,-0.20421427488327026f,-0.050184011459350586f,0.12480869889259338f,-0.189848855137825f,0.3545852601528168f,-0.3647043704986572f,0.396593302488327f,-0.4192400872707367f,-0.26248010993003845f}, +{0.24155375361442566f,0.32044556736946106f,0.3954955041408539f,0.1212681382894516f,0.0033026933670043945f,0.07572419941425323f,-0.11686752736568451f,-0.16056999564170837f,0.19561800360679626f,-0.32520344853401184f,0.2306625247001648f,-0.34033674001693726f,0.0820283591747284f,-0.8450090885162354f,0.25694453716278076f,-0.12947200238704681f}, +{-0.2722218334674835f,-0.2088075876235962f,-0.15798500180244446f,0.37669637799263f,-0.37393757700920105f,0.3686690330505371f,0.11292675137519836f,-0.2947862446308136f,-0.3764709532260895f,0.2424570620059967f,-0.10730250924825668f,-0.2837170362472534f,0.41839322447776794f,-0.019494730979204178f,-0.13046683371067047f,0.1112079843878746f}, +{-0.5616528391838074f,0.45646345615386963f,-0.2018718123435974f,0.2964705526828766f,0.07545611262321472f,0.27155816555023193f,-0.11297860741615295f,0.664657711982727f,-0.24509364366531372f,0.19522181153297424f,0.5596550703048706f,-0.28594130277633667f,-0.16718891263008118f,0.028074484318494797f,-0.4229755401611328f,0.05221513286232948f}, {0.4138670265674591f,0.1604653298854828f,0.056746453046798706f,0.036025404930114746f,0.3228367865085602f,-0.07083973288536072f,0.018455177545547485f,0.0059362053871154785f,0.40515169501304626f,0.014240056276321411f,-0.07738298177719116f,0.1407785713672638f,-0.13024571537971497f,-0.29546058177948f,-0.11976784467697144f,-0.35825538635253906f}, -{-0.7413668632507324f,0.1026708334684372f,0.12081471085548401f,-0.3019435703754425f,0.29976895451545715f,-0.2089935541152954f,-0.19728951156139374f,0.24360427260398865f,-0.3893685042858124f,-0.02222958207130432f,-0.4988212287425995f,-0.3810131847858429f,-0.34082454442977905f,-0.5941631197929382f,0.2266225963830948f,0.0005180099396966398f}, +{-1.1274402141571045f,0.9600362181663513f,0.12081471085548401f,-0.349691241979599f,0.29976895451545715f,-0.061989959329366684f,-0.4071444869041443f,0.13522475957870483f,-0.3893685042858124f,-0.02222958207130432f,0.3513525426387787f,-0.30210399627685547f,-0.19991017878055573f,-1.0830116271972656f,0.15741348266601562f,-1.4098620414733887f}, }; const float h3[16][16] = { - {-0.36079341173171997f,0.1464584767818451f,-0.317361980676651f,-0.3760572671890259f,-0.34049099683761597f,0.17843884229660034f,0.3332441747188568f,0.3036012351512909f,-0.2405819296836853f,0.04891335964202881f,0.6647762060165405f,0.4001283347606659f,-0.22401779890060425f,0.4277285635471344f,-0.05822409689426422f,0.14648514986038208f}, -{0.047732532024383545f,0.14185985922813416f,-0.2746029794216156f,-0.4051361083984375f,-0.6855432391166687f,0.8004894852638245f,-0.3198729455471039f,0.06247803568840027f,2.051791191101074f,-0.6851478815078735f,1.94772207736969f,-0.3805152475833893f,-0.071693055331707f,1.0943926572799683f,-0.2973291873931885f,-0.2905019223690033f}, + {-0.36079341173171997f,-0.7508866190910339f,1.1297551393508911f,-0.538090169429779f,1.0655514001846313f,-1.365544319152832f,0.3332441747188568f,0.3036012351512909f,-1.560882568359375f,-0.46699059009552f,-0.7533288598060608f,0.2455836981534958f,1.3695368766784668f,-1.2221437692642212f,-0.4832517206668854f,0.150726318359375f}, +{0.047732532024383545f,0.4048078954219818f,-0.7957146763801575f,-0.4415915906429291f,-0.7497909069061279f,0.48172199726104736f,-0.3198729455471039f,0.06247803568840027f,0.3792981505393982f,-0.616814136505127f,0.294821172952652f,-0.4651259481906891f,0.17083856463432312f,0.8202698230743408f,-0.2861880362033844f,-0.28870537877082825f}, {0.07903262972831726f,0.2790505588054657f,-0.07798504829406738f,0.04248586297035217f,-0.1963958442211151f,-0.19260792434215546f,-0.4038352966308594f,0.015906542539596558f,0.15353140234947205f,0.030178606510162354f,0.2488909661769867f,0.13805970549583435f,-0.0816211998462677f,-0.20733052492141724f,-0.3036302626132965f,0.054825395345687866f}, -{-0.30922991037368774f,-0.027659641578793526f,0.1773041933774948f,-0.3788892924785614f,-0.39630311727523804f,0.24171951413154602f,0.20021501183509827f,0.07002416253089905f,-0.2705947756767273f,-0.4869213402271271f,0.55600905418396f,0.41021624207496643f,-0.18743380904197693f,0.22692470252513885f,0.18151329457759857f,-0.02565847523510456f}, +{-0.30922991037368774f,-0.1632881909608841f,0.3019079566001892f,-0.3746798038482666f,-0.22990964353084564f,0.11132402718067169f,0.20021501183509827f,0.07002416253089905f,-0.22219358384609222f,-0.28733325004577637f,0.37440866231918335f,0.41021624207496643f,-0.028354128822684288f,0.08565498888492584f,0.17593181133270264f,-0.022988593205809593f}, {-0.39607733488082886f,-0.05481579899787903f,0.1976260244846344f,0.022423356771469116f,0.16892847418785095f,-0.27518749237060547f,0.16012099385261536f,0.3626593053340912f,-0.08640444278717041f,-0.11053556203842163f,-0.10529157519340515f,-0.31317979097366333f,-0.1530032455921173f,-0.1336749792098999f,0.22959044575691223f,0.19986507296562195f}, -{-0.37449589371681213f,0.040260959416627884f,0.06951090693473816f,0.17877109348773956f,0.4688447415828705f,-0.0568152479827404f,-0.18732719123363495f,0.22384825348854065f,-0.42837828397750854f,-0.16185910999774933f,0.15216808021068573f,0.19005391001701355f,0.07660079002380371f,0.06416161358356476f,0.40849316120147705f,-0.3371749818325043f}, -{0.4110594093799591f,0.2715781033039093f,-0.3257431089878082f,0.2142973244190216f,0.11818503588438034f,-0.05779394507408142f,-0.08670487999916077f,-0.25336313247680664f,-0.030661463737487793f,-0.06259563565254211f,-0.1344406008720398f,0.35313835740089417f,0.21155259013175964f,0.12332143634557724f,0.3126353323459625f,-0.3391006588935852f}, -{-0.40892091393470764f,0.0616367906332016f,-0.4007679224014282f,0.25968697667121887f,0.328382283449173f,-0.03144282102584839f,-0.23312048614025116f,-0.390264093875885f,0.28059282898902893f,-0.1559126079082489f,-0.1259572058916092f,-0.0003446042537689209f,-0.287761926651001f,-0.3555845618247986f,0.09450873732566833f,0.005298197269439697f}, -{0.10697010159492493f,-0.12228584289550781f,-0.37870171666145325f,0.21184906363487244f,-0.37222859263420105f,-0.17138728499412537f,-0.1382003128528595f,0.3493293821811676f,-0.360889196395874f,-0.3875247836112976f,0.42142823338508606f,-0.3482915461063385f,-0.3289247751235962f,-0.2186824083328247f,0.09620395302772522f,-0.06898030638694763f}, +{-0.37449589371681213f,0.2659645676612854f,-0.45420169830322266f,0.18866799771785736f,0.024692242965102196f,0.4492577016353607f,-0.18732719123363495f,0.22384825348854065f,-1.419227123260498f,-0.142959326505661f,0.019687024876475334f,0.19005391001701355f,-0.12263328582048416f,0.5829306840896606f,0.43119755387306213f,-0.3351086378097534f}, +{0.4110594093799591f,0.2715781033039093f,-0.3918847143650055f,0.37246426939964294f,-0.12695887684822083f,0.2014416754245758f,-0.08670487999916077f,-0.25336313247680664f,-0.030661463737487793f,-0.06259563565254211f,-0.1344406008720398f,0.35313835740089417f,-0.06009049713611603f,0.38011685013771057f,0.3126353323459625f,-0.3391006588935852f}, +{-0.40892091393470764f,0.511833667755127f,-0.8684166073799133f,0.08473247289657593f,-0.1197316125035286f,0.41766631603240967f,-0.23312048614025116f,-0.390264093875885f,0.23848757147789001f,-0.1559126079082489f,1.1041340827941895f,-0.0003446042537689209f,-0.6945624351501465f,0.08726350963115692f,0.1718367338180542f,0.005298197269439697f}, +{0.10697010159492493f,-0.1923011690378189f,-0.3204115331172943f,0.21184906363487244f,-0.37222859263420105f,-0.2404182255268097f,-0.1382003128528595f,0.3493293821811676f,-0.297639399766922f,-0.3875247836112976f,0.3332189917564392f,-0.3482915461063385f,-0.27231451869010925f,-0.26751258969306946f,0.09620395302772522f,-0.06898030638694763f}, {0.2847062647342682f,0.018552124500274658f,0.11435768008232117f,0.36562982201576233f,-0.047046810388565063f,0.30447837710380554f,0.2430230677127838f,0.2909286320209503f,-0.2802048921585083f,0.18043199181556702f,0.41849127411842346f,-0.287167489528656f,0.24394884705543518f,-0.14084559679031372f,-0.10168051719665527f,0.010465055704116821f}, -{0.15459725260734558f,0.28715085983276367f,-0.1975911408662796f,-0.10847480595111847f,-0.338723361492157f,0.37625446915626526f,-0.08742031455039978f,0.05785742402076721f,0.5200075507164001f,-0.4833226799964905f,0.5273776054382324f,-0.30447322130203247f,-0.10086123645305634f,0.042644109576940536f,0.4391385018825531f,0.3226448595523834f}, -{-0.408692330121994f,-0.15486499667167664f,0.3066166341304779f,0.0922636091709137f,0.1873702108860016f,-0.4056578278541565f,0.03285527229309082f,0.38763079047203064f,-0.20705322921276093f,-0.25883403420448303f,0.12809070944786072f,0.03996849060058594f,-0.4213770925998688f,-0.472481369972229f,-0.3355949819087982f,0.31626954674720764f}, -{-0.2991822361946106f,0.3794580399990082f,0.06649655848741531f,-0.11694668978452682f,0.2296813577413559f,0.09872535616159439f,-0.11253207921981812f,0.34576353430747986f,0.04814547300338745f,-0.35770976543426514f,-0.044228196144104004f,-0.36229726672172546f,0.1595783829689026f,-0.28000524640083313f,0.36124154925346375f,-0.16869547963142395f}, -{-0.2675279378890991f,-0.1804099678993225f,0.5291721224784851f,-0.09164145588874817f,0.8961657881736755f,-0.9392423629760742f,-0.32875844836235046f,-0.31893211603164673f,-2.9557993412017822f,-0.6771930456161499f,-0.8014379739761353f,-0.6284971237182617f,0.332326203584671f,-1.0134690999984741f,0.3772561252117157f,0.20396418869495392f}, -{-0.015470266342163086f,-0.4175601005554199f,0.4652104079723358f,0.344943642616272f,0.1992327719926834f,-0.4663916528224945f,0.05196094512939453f,-0.008358269929885864f,-0.4575410783290863f,-0.5083949565887451f,-0.2538931965827942f,-0.11511552333831787f,0.3527691960334778f,-0.12093909084796906f,0.01653306372463703f,-0.45850178599357605f}, -{0.1863725483417511f,0.08846206963062286f,-0.050088606774806976f,-0.46936851739883423f,0.5272957682609558f,0.07133814692497253f,0.04860696196556091f,0.17769548296928406f,-1.3204635381698608f,0.06790181249380112f,-0.14967891573905945f,0.19592127203941345f,0.4656137526035309f,0.1081087589263916f,-0.06106513738632202f,-0.11734148859977722f}, +{0.15459725260734558f,0.3942316770553589f,0.013690208084881306f,-0.09359592944383621f,-0.07358632236719131f,0.10678815841674805f,-0.08742031455039978f,0.05785742402076721f,-0.09137898683547974f,-0.343021959066391f,0.3351368010044098f,-0.30447322130203247f,0.01849541999399662f,-0.2119709849357605f,0.44943687319755554f,0.32524192333221436f}, +{-0.408692330121994f,-0.15511342883110046f,0.17088568210601807f,0.0922636091709137f,0.07895755022764206f,-0.2857224643230438f,0.03285527229309082f,0.38763079047203064f,-0.20705322921276093f,-0.25883403420448303f,0.12809070944786072f,0.03996849060058594f,-0.45054206252098083f,-0.3511306345462799f,-0.3359401822090149f,0.31680548191070557f}, +{-0.2991822361946106f,0.3794580399990082f,-0.07897943258285522f,-0.05932474136352539f,0.08582660555839539f,0.24227938055992126f,-0.11253207921981812f,0.34576353430747986f,0.04814547300338745f,-0.35770976543426514f,-0.044228196144104004f,-0.36229726672172546f,0.015840977430343628f,-0.13475483655929565f,0.36124154925346375f,-0.16869547963142395f}, +{-0.2675279378890991f,-0.3460475504398346f,0.22180698812007904f,-0.09016680717468262f,0.2846950590610504f,-0.2946321964263916f,-0.32875844836235046f,-0.31893211603164673f,-1.2886390686035156f,-0.9467211365699768f,-1.729813814163208f,-0.5661335587501526f,0.5964445471763611f,-0.4080161154270172f,0.37027448415756226f,0.2071458399295807f}, +{-0.015470266342163086f,-0.42435455322265625f,0.4734625816345215f,0.3536997139453888f,0.18134212493896484f,-0.4675792157649994f,0.05196094512939453f,-0.008358269929885864f,-1.2629804611206055f,-0.5019198060035706f,0.025087250396609306f,-0.11511552333831787f,0.38278472423553467f,-0.11798432469367981f,0.054047591984272f,-0.45645639300346375f}, +{0.1863725483417511f,0.2275526225566864f,-0.5136680603027344f,-0.45637550950050354f,-0.3339087963104248f,0.8623207807540894f,0.04860696196556091f,0.17769548296928406f,0.06988368183374405f,0.21612535417079926f,-0.32679811120033264f,0.19592127203941345f,-0.21065615117549896f,0.9122236967086792f,-0.04827544093132019f,-0.114141084253788f}, }; -const float hout[16] = { 0.45773375034332275f,0.3859798014163971f,-0.29981717467308044f,-0.03291182219982147f,-0.8433356881141663f,1.002862572669983f,0.0030125975608825684f,0.15066689252853394f,-2.8478612899780273f,-0.10332534462213516f,1.0703125f,-0.1749168038368225f,-0.3780519664287567f,1.3915053606033325f,0.34188297390937805f,-0.17065440118312836f }; - -const float b1[16] = { 1.1156562566757202f,1.2580926418304443f,-1.7145336866378784f,0.18262852728366852f,0.7823516130447388f,0.998382568359375f,-0.058932315558195114f,-1.9845973253250122f,0.21749649941921234f,-1.0451427698135376f,0.5739218592643738f,1.1615904569625854f,-0.3700066804885864f,-1.0825129747390747f,-1.087764859199524f,1.4952983856201172f }; - -const float b2[16] = { -0.3779629170894623f,-1.1113404035568237f,-1.4564176797866821f,-0.6393038630485535f,-0.6939148902893066f,-0.06903098523616791f,0.2865044176578522f,-0.3734967112541199f,-1.20063054561615f,-1.912178635597229f,-0.13764147460460663f,0.5186623334884644f,-0.21744106709957123f,2.212801933288574f,0.06957299262285233f,0.9868263602256775f }; - -const float b3[16] = { -1.963319182395935f,-0.5935878157615662f,-0.005241615232080221f,-0.24495701491832733f,0.04313206300139427f,0.9367193579673767f,-0.45353031158447266f,-0.6562485098838806f,-0.07319840788841248f,-0.035821571946144104f,-0.0942746177315712f,-0.0137743866071105f,-0.5863775610923767f,0.59046870470047f,-1.1678985357284546f,-0.3959362506866455f }; - -const float bout[1] = { -0.09139688313007355f }; +const float hout[16] = { 0.45773375034332275f,0.8770678043365479f,-0.5642080903053284f,-0.06896117329597473f,-0.44897395372390747f,1.097171425819397f,0.0030125975608825684f,0.15066689252853394f,-2.6636300086975098f,-0.20573356747627258f,2.1506714820861816f,-0.12040673196315765f,-0.5546231865882874f,0.8441613912582397f,0.3788313567638397f,-0.1722545176744461f }; + +const float b1[16] = { 0.29917195439338684f,1.240564227104187f,-1.7145336866378784f,-0.009053205139935017f,0.8226833939552307f,1.1139267683029175f,-0.058932315558195114f,0.9074918627738953f,0.2987629771232605f,-1.1111444234848022f,0.5792149901390076f,1.1139918565750122f,-0.37065640091896057f,-1.0110033750534058f,-1.087764859199524f,1.4034990072250366f }; + +const float b2[16] = { 0.1707206815481186f,-0.9527223110198975f,-1.4564176797866821f,-0.686187207698822f,-0.6939148902893066f,-0.07072640210390091f,0.33335962891578674f,-0.42512816190719604f,-1.3534284830093384f,-1.912178635597229f,0.046489447355270386f,0.5405064821243286f,-0.07918518036603928f,1.924153208732605f,0.043257370591163635f,0.741142988204956f }; + +const float b3[16] = { -1.963319182395935f,-0.3596874177455902f,-0.11595775187015533f,-0.21615983545780182f,-0.1688675433397293f,1.119028925895691f,-0.45353031158447266f,-0.6562485098838806f,0.2832948863506317f,0.031506508588790894f,-0.27314963936805725f,-0.10737795382738113f,-0.3551398515701294f,0.7503713369369507f,-1.1661463975906372f,-0.39268162846565247f }; + +const float bout[1] = { 0.02880154363811016f }; /////////////////////////////////////////////////////////////////////////////////////////////RL float input_RL[num_input_RL] = { 0.0f }; @@ -1037,8 +1037,8 @@ input_NN[ind] = torq.sen / 10000.0f + 0.5f; ind = ind + 1; for(int i=0; i<numfuture_f; i++) { -// input_NN[ind] = (f_future[time_interval*i+time_interval] - torq.sen)/10000.0f+0.5f; - input_NN[ind] = (f_future[time_interval*i+time_interval])/10000.0f+0.5f; + input_NN[ind] = (f_future[time_interval*i+time_interval] - torq.sen)/10000.0f+0.5f; +// input_NN[ind] = (f_future[time_interval*i+time_interval])/10000.0f+0.5f; ind = ind + 1; }