![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
for learning
Diff: main.cpp
- Revision:
- 216:a81419fb58ea
- Parent:
- 215:9aa288c10f68
- Child:
- 217:ea3ce5d72ae3
diff -r 9aa288c10f68 -r a81419fb58ea main.cpp --- a/main.cpp Thu Dec 24 08:15:29 2020 +0000 +++ b/main.cpp Thu Dec 24 13:18:52 2020 +0000 @@ -1,4 +1,4 @@ -//201224_2 +//201224_3 #include "mbed.h" #include "FastPWM.h" #include "INIT_HW.h" @@ -199,72 +199,71 @@ float input_NN[num_input] = { 0.0f }; const float h1[num_input][16] = { - {-0.3518959879875183f,-1.0181971788406372f,0.5238839387893677f,0.07460802793502808f,0.4083598852157593f,0.5267895460128784f,-0.24204020202159882f,0.022494137287139893f,-0.38182884454727173f,0.1710560917854309f,-0.6304952502250671f,-0.24469460546970367f,0.07800555229187012f,-0.11156265437602997f,0.9230948686599731f,0.01127579715102911f}, -{-0.23303905129432678f,-0.24711905419826508f,0.4181930422782898f,-0.2855757474899292f,-0.4139590263366699f,0.6357643604278564f,-0.33242931962013245f,0.33744025230407715f,0.019223570823669434f,0.025203019380569458f,0.0015196951571851969f,-0.32244545221328735f,0.07627367973327637f,0.36681148409843445f,0.2662626802921295f,-0.055823683738708496f}, -{0.054309576749801636f,-0.49540218710899353f,0.3860630691051483f,-0.3997206389904022f,0.37840962409973145f,-0.14458975195884705f,-0.3337523639202118f,-0.21087387204170227f,0.18194907903671265f,-0.15486115217208862f,-0.48218241333961487f,0.30044838786125183f,-0.10916683077812195f,0.13324618339538574f,-0.018999867141246796f,0.2987367808818817f}, -{-0.28941866755485535f,0.2667725384235382f,-0.4305540919303894f,-0.3544938564300537f,-0.3382750153541565f,0.1611849069595337f,-0.4222949147224426f,0.2507844567298889f,0.405910849571228f,0.15534931421279907f,0.0912986472249031f,-0.21454837918281555f,-0.35986700654029846f,-0.4057389199733734f,-0.28181108832359314f,-0.042290735989809036f}, -{0.260015070438385f,0.32970598340034485f,-0.8912553787231445f,-0.3760731518268585f,0.08130717277526855f,-0.6682697534561157f,0.35346728563308716f,0.05169829726219177f,0.39578813314437866f,0.3265618085861206f,0.1725350022315979f,-0.23878204822540283f,0.3847886323928833f,0.3495698571205139f,-0.6733472347259521f,0.2500562071800232f}, -{0.07367211580276489f,0.7450180053710938f,-0.6315812468528748f,0.21967214345932007f,0.4170142412185669f,-0.770605206489563f,0.16131609678268433f,-0.05181002616882324f,0.03649970889091492f,0.3132137656211853f,0.716629147529602f,0.09533099830150604f,-0.004373282194137573f,0.35536396503448486f,-0.6000161170959473f,0.3825781047344208f}, -{-0.1849803626537323f,-0.40095481276512146f,-0.2245466113090515f,0.10853719711303711f,-0.34670042991638184f,-0.6805928349494934f,-0.07871395349502563f,-0.3424152731895447f,-0.0723131000995636f,-0.09276700019836426f,-0.2896198034286499f,0.384247362613678f,0.1583765149116516f,0.25456663966178894f,-0.6039044260978699f,0.12134073674678802f}, -{0.3363311290740967f,-0.12490702420473099f,-0.04714484512805939f,0.2931549549102783f,-0.2531799077987671f,-0.3935620188713074f,-0.15988385677337646f,-0.16074800491333008f,-0.3888390362262726f,-0.03829273581504822f,-0.06867220997810364f,0.09743418544530869f,-0.03030523657798767f,0.038140591233968735f,0.038169119507074356f,-0.34604939818382263f}, -{-0.008942186832427979f,0.6577344536781311f,-0.4952816069126129f,-0.26002514362335205f,0.369967520236969f,0.021473055705428123f,0.06158176064491272f,0.3959408402442932f,-0.011539667844772339f,-0.3851383328437805f,0.126651793718338f,-0.17609961330890656f,-0.3491899371147156f,-0.46013858914375305f,0.06334633380174637f,-0.24532243609428406f}, -{-0.23328730463981628f,0.4614630937576294f,-0.2081146091222763f,-0.14789578318595886f,-0.1547950804233551f,-0.39302149415016174f,-0.09938845038414001f,0.10942506790161133f,-0.3328583538532257f,0.32593780755996704f,-0.3129696547985077f,0.019227905198931694f,0.025072604417800903f,-0.15357577800750732f,-0.2597353756427765f,-0.10979597270488739f}, -{-0.2889084219932556f,0.35974031686782837f,-0.487824410200119f,0.358765184879303f,-0.4070855379104614f,-0.48963862657546997f,-0.14795801043510437f,0.12666010856628418f,0.2193526029586792f,0.2858560085296631f,-0.6543271541595459f,0.16494837403297424f,-0.35532402992248535f,-0.06058239936828613f,0.07391873747110367f,0.29227620363235474f}, -{-0.349159836769104f,0.23408935964107513f,-0.28113874793052673f,-0.09636816382408142f,-0.3470844030380249f,0.09159677475690842f,-0.24872183799743652f,-0.3441091775894165f,-0.20228171348571777f,-0.3132234513759613f,-0.38526651263237f,-0.07960613816976547f,0.11759966611862183f,0.10377488285303116f,0.2513485848903656f,-0.263491153717041f}, -{0.38546842336654663f,0.1190636157989502f,-0.05863933265209198f,-0.41764265298843384f,-0.4134422838687897f,-0.09244964271783829f,0.298126757144928f,-0.39963799715042114f,-0.06526103615760803f,0.03604122996330261f,-0.409576952457428f,0.09560509771108627f,-0.30289945006370544f,0.14713193476200104f,-0.0909358337521553f,0.1905267983675003f}, -{-0.42283523082733154f,0.17752918601036072f,0.05169850215315819f,-0.14728012681007385f,-0.37331435084342957f,0.32072553038597107f,-0.09241300821304321f,-0.04799109697341919f,-0.17356249690055847f,-0.053030580282211304f,0.2975623309612274f,-0.12490103393793106f,-0.3399311900138855f,0.17119969427585602f,0.3467433452606201f,-0.32378605008125305f}, -{0.2842629551887512f,0.14254522323608398f,-0.07260823994874954f,-0.1726883053779602f,-0.16769343614578247f,0.362951397895813f,-0.18842191994190216f,0.35883063077926636f,-0.32441917061805725f,0.3678022027015686f,0.19621485471725464f,0.4039776921272278f,-0.006959974765777588f,-0.07163886725902557f,0.17139792442321777f,-0.4028019607067108f}, -{0.30670469999313354f,-0.07149137556552887f,-0.06005222350358963f,-0.24774791300296783f,0.2930166721343994f,0.0734730213880539f,-0.2875429093837738f,0.34532618522644043f,-0.07908278703689575f,0.264565646648407f,-0.24093548953533173f,-0.3791404664516449f,0.24430310726165771f,0.11721959710121155f,-0.20590196549892426f,-0.20737025141716003f}, -{0.06869709491729736f,-0.28333309292793274f,-0.42365720868110657f,-0.3430131673812866f,-0.4249112606048584f,-0.367571085691452f,-0.2120281457901001f,-0.19189448654651642f,0.18253427743911743f,-0.026109665632247925f,0.29364481568336487f,-0.049624159932136536f,0.24209386110305786f,-0.28560784459114075f,0.2603754699230194f,-0.24946027994155884f}, + {-1.6017948389053345f,1.2721383571624756f,0.1310378611087799f,-0.9444252848625183f,-1.9589552879333496f,1.1329879760742188f,-0.17743819952011108f,-0.19157131016254425f,-0.39761483669281006f,0.02001183293759823f,0.5025057196617126f,-2.509382724761963f,-0.2675858736038208f,0.27560269832611084f,-0.2611466646194458f,-0.9627107977867126f}, +{-1.2710213661193848f,0.9135757684707642f,-0.3988758325576782f,-0.7979171872138977f,-1.4895585775375366f,0.5568610429763794f,-0.4116867780685425f,-0.261433482170105f,-0.22742684185504913f,0.2772603929042816f,0.118864506483078f,-1.5505203008651733f,0.23985113203525543f,-0.2809593081474304f,-0.21292872726917267f,-0.6193060874938965f}, +{-1.1586071252822876f,0.7516070604324341f,0.36955419182777405f,-0.9032031297683716f,-0.9722328782081604f,0.5363096594810486f,0.2916664779186249f,-0.016872992739081383f,-0.34971633553504944f,0.2836141288280487f,-0.054457396268844604f,-0.9038598537445068f,-0.0020234500989317894f,0.19621078670024872f,0.056768983602523804f,-1.1061573028564453f}, +{-0.7506084442138672f,0.1879994422197342f,0.40358296036720276f,0.12524257600307465f,-0.5177642107009888f,-0.18764258921146393f,-0.11764177680015564f,0.31180232763290405f,-0.20574431121349335f,0.42218565940856934f,0.16467393934726715f,0.3004089593887329f,-0.1665881872177124f,0.09486014395952225f,-0.3007376194000244f,-0.8816207051277161f}, +{0.7436127662658691f,-0.604726254940033f,-0.005224883556365967f,0.9320474863052368f,0.5615028142929077f,-0.8275365829467773f,0.13140985369682312f,0.018719080835580826f,-0.24859893321990967f,0.23700864613056183f,-0.41653650999069214f,1.252004861831665f,-0.0686110407114029f,0.23053120076656342f,-0.39249828457832336f,-0.6377205848693848f}, +{3.0718040466308594f,-3.262662887573242f,0.22110894322395325f,2.670456647872925f,2.9312491416931152f,-3.062858819961548f,0.16770240664482117f,-0.1752457618713379f,-0.304975301027298f,0.24974356591701508f,-2.912475347518921f,3.297006845474243f,-0.2682695984840393f,0.3757273256778717f,-0.4196912348270416f,1.0734145641326904f}, +{-1.2198433876037598f,1.5182578563690186f,-0.2540779709815979f,-1.8283756971359253f,-1.570626139640808f,1.7989088296890259f,0.06107431650161743f,-0.7636352777481079f,0.3089294731616974f,-0.09506343305110931f,2.775860548019409f,0.7932590246200562f,-0.17504744231700897f,0.2239564061164856f,-0.15860587358474731f,-0.7237789630889893f}, +{0.7539365291595459f,-0.9152541160583496f,-0.2703247666358948f,0.3871593773365021f,0.3573713004589081f,-0.712091326713562f,-0.18203827738761902f,-0.5724472999572754f,-0.17589353024959564f,-0.025821663439273834f,0.3012785017490387f,0.5540553331375122f,0.3776646554470062f,0.029355080798268318f,0.0436977744102478f,1.1350784301757812f}, +{0.6773941516876221f,-0.1407381296157837f,0.10406997799873352f,-0.31886449456214905f,0.2701631486415863f,-0.2895267903804779f,-0.07359349727630615f,-0.522844135761261f,-0.4761183261871338f,0.22720466554164886f,-0.11068277060985565f,0.17022143304347992f,0.23315370082855225f,0.15179778635501862f,-0.31029027700424194f,0.851940393447876f}, +{0.11661386489868164f,-0.3948979079723358f,0.18748918175697327f,-0.2878238558769226f,0.28554558753967285f,0.11674453318119049f,-0.3036908507347107f,-0.1508290320634842f,-0.14107836782932281f,-0.5925581455230713f,0.2786004841327667f,-1.0318316221237183f,0.37844526767730713f,-0.270053893327713f,0.35390153527259827f,0.38183316588401794f}, +{0.4711846709251404f,0.11557799577713013f,0.3775894343852997f,0.0314268134534359f,0.03386480361223221f,0.016547810286283493f,-0.20654654502868652f,-0.06258935481309891f,-0.4769713580608368f,-0.07612045109272003f,0.6390635967254639f,-0.8360038995742798f,-0.06711658090353012f,-0.030321964994072914f,0.2710213363170624f,-0.054686423391103745f}, +{-0.37094420194625854f,-0.2944038212299347f,-0.40945154428482056f,-0.18097494542598724f,0.14135384559631348f,0.021318335086107254f,0.15575703978538513f,0.29287639260292053f,-0.12214788794517517f,0.1086469367146492f,-0.14901117980480194f,-0.15198558568954468f,0.1470927745103836f,-0.03396562486886978f,0.10656675696372986f,0.06443876773118973f}, +{0.025174643844366074f,-0.12816596031188965f,0.2015570104122162f,0.1076304167509079f,0.45414742827415466f,0.19509439170360565f,-0.24415965378284454f,0.013022400438785553f,-0.10836649686098099f,-0.29661229252815247f,0.09127697348594666f,-0.21214918792247772f,0.09341105818748474f,0.01174785103648901f,-0.22613362967967987f,-0.3625008761882782f}, +{-0.04146391525864601f,-0.02673570066690445f,0.41918185353279114f,-0.1233106479048729f,-0.07927072793245316f,-0.1876136064529419f,-0.32497477531433105f,-0.4840133786201477f,-0.044291287660598755f,-0.3259299099445343f,0.04178468510508537f,-0.0003480979357846081f,-0.31783685088157654f,-0.05072624981403351f,0.04871204495429993f,-0.08137178421020508f}, +{0.1422140747308731f,0.18844546377658844f,0.20596781373023987f,-0.2328251153230667f,0.34344229102134705f,0.06260570883750916f,0.042680561542510986f,0.07508613914251328f,0.4000869691371918f,-0.010638000443577766f,0.13212932646274567f,-0.657844066619873f,0.10472581535577774f,-0.038563571870326996f,0.06784489750862122f,-0.2556094229221344f}, +{0.15386898815631866f,-0.49337783455848694f,-0.4106670916080475f,-0.4150790572166443f,-0.05264211446046829f,-0.05708514153957367f,-0.15809619426727295f,-0.20627009868621826f,0.27094385027885437f,-0.09812130033969879f,-0.3514001667499542f,-0.9586353898048401f,-0.275861918926239f,0.02052518166601658f,-0.08373728394508362f,-0.0018482634332031012f}, }; const float h2[16][16] = { - {-0.055980950593948364f,0.23325034976005554f,0.1310378611087799f,0.3538874685764313f,-0.3786364793777466f,0.3037426769733429f,-0.17743819952011108f,0.03198641538619995f,-0.25820767879486084f,-0.025972992181777954f,-0.1812897026538849f,-0.19700877368450165f,-0.23905162513256073f,0.3336930572986603f,-0.2611466646194458f,-0.14968061447143555f}, -{0.6830940842628479f,0.3085605204105377f,-1.0774949789047241f,-0.63385409116745f,-0.9465451836585999f,-0.005713187158107758f,-1.1153970956802368f,-0.6576376557350159f,-0.18814027309417725f,0.2273702323436737f,-0.2186730057001114f,-0.09930881857872009f,0.3377574682235718f,-0.9058500528335571f,-0.21292872726917267f,0.6135957837104797f}, -{-0.8244589567184448f,0.3188628852367401f,0.4108174741268158f,-0.4539192020893097f,-0.16654692590236664f,0.10132119059562683f,0.5420822501182556f,0.13426877558231354f,-0.1720905601978302f,0.229490727186203f,-0.29371505975723267f,-0.13699811697006226f,-0.28904634714126587f,0.337862104177475f,0.056768983602523804f,-0.5893235802650452f}, -{-0.28563398122787476f,0.07789990305900574f,0.40358296036720276f,0.3720850646495819f,-0.03832319378852844f,-0.1494518518447876f,-0.11764177680015564f,0.34294649958610535f,0.054388612508773804f,0.3634087145328522f,0.1569826900959015f,0.28783395886421204f,-0.13846668601036072f,0.12138035893440247f,-0.3007376194000244f,0.12193700671195984f}, -{0.1812863051891327f,0.25741907954216003f,-0.005224883556365967f,0.3340524137020111f,0.024127095937728882f,0.11559751629829407f,0.13140985369682312f,-0.02607312798500061f,0.060811251401901245f,0.1730591356754303f,0.4128219783306122f,0.03628826141357422f,-0.040624260902404785f,0.2442089021205902f,-0.39249828457832336f,-0.21546570956707f}, -{0.30592480301856995f,-0.3289546072483063f,0.2873966097831726f,0.3854629099369049f,0.35946568846702576f,-0.36090072989463806f,0.3797028660774231f,-0.31257379055023193f,0.018147015944123268f,0.17989537119865417f,-0.191977858543396f,0.26149240136146545f,-0.5889873504638672f,0.4767233431339264f,-0.4196912348270416f,-0.6381170749664307f}, -{0.03675055503845215f,-0.05131736397743225f,-0.2540779709815979f,-0.4151476323604584f,-0.3318796753883362f,0.2645241320133209f,0.06107431650161743f,-0.3474422097206116f,0.4012340009212494f,0.12852928042411804f,0.2119675576686859f,0.39421865344047546f,-0.14612942934036255f,0.4053405821323395f,-0.15860587358474731f,-0.00642770528793335f}, -{-0.011466562747955322f,-0.293976753950119f,-0.2703247666358948f,0.13940533995628357f,-0.3086448609828949f,-0.10881850123405457f,-0.18203827738761902f,-0.3606947958469391f,0.05907437205314636f,0.17521318793296814f,0.16556969285011292f,-0.017545759677886963f,0.4063515365123749f,0.1637323796749115f,0.0436977744102478f,0.21962454915046692f}, -{0.1453019678592682f,0.31070712208747864f,0.10406997799873352f,-0.34301185607910156f,-0.14203324913978577f,0.1393299400806427f,-0.07359349727630615f,-0.4255761206150055f,-0.24196511507034302f,0.4100019037723541f,-0.2432931661605835f,0.4171271026134491f,0.26163145899772644f,0.24838712811470032f,-0.31029027700424194f,0.24932292103767395f}, -{-0.09909564256668091f,-0.22814129292964935f,0.18748918175697327f,-0.08129695057868958f,0.17022588849067688f,0.2918822467327118f,-0.3036908507347107f,-0.09228748083114624f,0.024910658597946167f,-0.4239048957824707f,0.050207048654556274f,-0.4021540582180023f,0.4068380892276764f,-0.20195016264915466f,0.35390153527259827f,0.03321918845176697f}, -{0.27012309432029724f,0.11061021685600281f,-0.11031246930360794f,-0.2462926208972931f,-0.47244739532470703f,-0.11755365878343582f,-0.8120853900909424f,-0.5518144965171814f,-0.44141459465026855f,0.08167347311973572f,0.41236647963523865f,-0.19175507128238678f,0.17540761828422546f,-0.7689425349235535f,0.2710213363170624f,0.032591644674539566f}, -{-0.34531110525131226f,-0.39544427394866943f,-0.40925148129463196f,0.07428228110074997f,0.16746854782104492f,-0.011973470449447632f,0.15573780238628387f,0.4095241129398346f,-0.11885038018226624f,0.2575679123401642f,-0.36203885078430176f,0.2510797083377838f,0.17548120021820068f,-0.001581403543241322f,0.10656675696372986f,-0.06930389255285263f}, -{-0.01594102382659912f,-0.19719429314136505f,0.2015570104122162f,0.23486098647117615f,0.36742570996284485f,0.19432035088539124f,-0.24415965378284454f,0.16870906949043274f,-0.1409781575202942f,-0.15576940774917603f,-0.05214834213256836f,-0.16751256585121155f,0.12201771140098572f,0.031148135662078857f,-0.22613362967967987f,-0.3668502867221832f}, -{-0.05743904411792755f,-0.10105487704277039f,0.37456682324409485f,-0.04381980374455452f,-0.24536658823490143f,-0.25192296504974365f,-0.2841794490814209f,-0.34860795736312866f,-0.12634605169296265f,-0.19223688542842865f,-0.13938084244728088f,-0.1388394832611084f,-0.24564625322818756f,-0.08797869831323624f,0.04871204495429993f,0.18949538469314575f}, -{0.29601532220840454f,-0.008572280406951904f,0.4535497725009918f,0.3231527507305145f,0.7357798218727112f,-0.31015023589134216f,0.43387073278427124f,0.3858222961425781f,0.3131316900253296f,0.11613044142723083f,-0.22509463131427765f,-0.3847343325614929f,-0.512644350528717f,0.13419762253761292f,0.06784489750862122f,-0.3282114565372467f}, -{-0.009295972064137459f,-0.35415053367614746f,-0.3785935640335083f,0.04678218811750412f,-0.05916179344058037f,0.028057783842086792f,-0.19932891428470612f,-0.004681884776800871f,0.27984046936035156f,0.021969109773635864f,-0.42253369092941284f,-0.02782580256462097f,-0.2832367718219757f,0.035722918808460236f,-0.08373728394508362f,0.2868802547454834f}, + {-0.9739745259284973f,3.579744815826416f,-0.06966331601142883f,0.8622938990592957f,-0.21907491981983185f,2.2829554080963135f,-0.13155855238437653f,-0.014519207179546356f,-0.43008196353912354f,-0.1415480375289917f,0.17231711745262146f,-4.9480390548706055f,-0.02454538829624653f,-1.7999197244644165f,-0.38519009947776794f,1.4918317794799805f}, +{0.03609159216284752f,-0.6491178274154663f,0.057057321071624756f,-0.5475255846977234f,-0.35503754019737244f,-3.0916311740875244f,-0.5200656652450562f,-0.42126399278640747f,-0.33757925033569336f,0.2895788848400116f,-0.4909915030002594f,-1.1257127523422241f,0.18442146480083466f,1.348382830619812f,-0.5171104669570923f,-2.655162811279297f}, +{-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.15409719944000244f,0.4271918833255768f,-0.2894435524940491f,0.4524352252483368f,0.08946844935417175f,-0.24254196882247925f,-0.5646932125091553f,0.2643083930015564f,0.26211628317832947f,0.2953031361103058f,0.0909804254770279f,0.8597109913825989f,-0.5144365429878235f,-2.37484073638916f,-0.026095986366271973f,0.29753774404525757f}, +{-0.7763098478317261f,2.959994316101074f,-0.25313520431518555f,0.5777999758720398f,0.036378175020217896f,0.7788732051849365f,-0.5079860091209412f,-0.20636579394340515f,-0.024399548768997192f,-0.39465832710266113f,-0.4901541471481323f,-3.3827083110809326f,-0.013386494480073452f,-1.876047134399414f,-0.6391417384147644f,0.6140359044075012f}, +{0.020159810781478882f,0.545926034450531f,-0.3519742488861084f,-0.17923703789710999f,-0.3015052080154419f,-1.5342668294906616f,-0.7026005387306213f,-0.12369749695062637f,-0.23047015070915222f,0.3579089343547821f,-0.2382185161113739f,-5.193862438201904f,-0.3443910777568817f,1.945488691329956f,0.014947117306292057f,-1.2414220571517944f}, +{-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.3839884400367737f,0.6259503960609436f,0.33083590865135193f,0.04438639059662819f,-0.14358049631118774f,0.12416914105415344f,-0.09043094515800476f,-0.3003333508968353f,0.2600560486316681f,-0.37898191809654236f,0.4972154498100281f,-0.2750113010406494f,-0.31673234701156616f,-0.015966646373271942f,-0.08780939131975174f,0.328056275844574f}, +{-0.4527643918991089f,0.3202667832374573f,-0.11379697918891907f,0.0684560090303421f,0.041274964809417725f,-0.40635451674461365f,-0.2745489478111267f,0.031847670674324036f,0.06103590130805969f,-0.38046833872795105f,-0.45007404685020447f,-0.5276026725769043f,-0.37024784088134766f,-0.3135625123977661f,-0.3714982867240906f,-0.12828999757766724f}, +{0.2802984118461609f,0.5001301765441895f,-0.13502129912376404f,0.6260269284248352f,0.12987366318702698f,0.6041213870048523f,0.2711336314678192f,-0.3632148504257202f,-0.13619378209114075f,0.16938945651054382f,0.5018476247787476f,0.3686026930809021f,0.3811538517475128f,-0.5396527647972107f,-0.19131632149219513f,0.09156869351863861f}, +{-1.5928384065628052f,0.23942683637142181f,0.0457797646522522f,-0.6350169777870178f,-0.03321319818496704f,0.08973085880279541f,-0.18186365067958832f,-0.3142535090446472f,-0.050184011459350586f,0.12480869889259338f,-0.5123732089996338f,-4.090933799743652f,-0.4121001660823822f,1.199095368385315f,-0.18886037170886993f,-0.7048641443252563f}, +{0.03677457198500633f,0.4954114556312561f,0.3954955041408539f,0.2689988911151886f,0.0033026933670043945f,1.278443694114685f,-0.4117635190486908f,-0.24394789338111877f,0.3487861454486847f,-0.32520344853401184f,0.14627091586589813f,-0.9104770421981812f,-0.07545550167560577f,-1.3930959701538086f,0.008092201314866543f,-1.8283593654632568f}, +{-0.31720414757728577f,-0.21001535654067993f,-0.15798500180244446f,0.3665239214897156f,-0.37393757700920105f,0.37094148993492126f,0.11292675137519836f,-0.2947862446308136f,-0.3764709532260895f,0.2424570620059967f,-0.1080506220459938f,-0.2837170362472534f,0.41839322447776794f,-0.01957082748413086f,-0.12957632541656494f,0.10856001079082489f}, +{0.03818705305457115f,0.27717405557632446f,-0.2018718123435974f,0.06585641950368881f,0.07545611262321472f,0.05265878140926361f,-0.11297860741615295f,-0.21416273713111877f,-0.24509364366531372f,0.19522181153297424f,0.351835161447525f,-0.2859584093093872f,-0.16718891263008118f,0.23180222511291504f,-0.23956191539764404f,-0.07242263853549957f}, +{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}, +{-1.0752074718475342f,-2.8200089931488037f,0.12081471085548401f,-0.12609876692295074f,0.29976895451545715f,0.4510769844055176f,-0.2826606035232544f,0.18327592313289642f,-0.3893685042858124f,-0.02222958207130432f,-0.19482164084911346f,-0.37641236186027527f,-0.19991017878055573f,-1.0054714679718018f,0.06622982025146484f,1.2732210159301758f}, }; const float h3[16][16] = { - {-0.011498991400003433f,-0.14559394121170044f,-0.06966331601142883f,-0.5719305872917175f,-0.21907491981983185f,0.7517984509468079f,0.6887433528900146f,0.0904630720615387f,-1.0889477729797363f,-0.28902721405029297f,-2.3065438270568848f,-0.10159772634506226f,0.23481115698814392f,-0.032193321734666824f,-0.060674071311950684f,0.22100424766540527f}, -{0.11036357283592224f,-0.3038245439529419f,0.057057321071624756f,0.08777192234992981f,-0.35503754019737244f,-0.29007279872894287f,-0.33918139338493347f,-0.2990124225616455f,-0.33757925033569336f,0.2895788848400116f,-0.3337714970111847f,-0.37158891558647156f,0.33698758482933044f,0.16647490859031677f,-0.3480874300003052f,-0.2740727365016937f}, -{-0.2946450114250183f,0.003037691116333008f,-0.061119019985198975f,0.4629787802696228f,0.05568113923072815f,-0.3591650128364563f,-0.3925563097000122f,-0.08465918898582458f,0.46576768159866333f,0.1319389045238495f,0.4200381338596344f,0.3004753887653351f,0.29665684700012207f,-0.5471781492233276f,0.08652284741401672f,-0.1951722800731659f}, -{0.014514091424643993f,-0.38710832595825195f,-0.2894435524940491f,0.40405750274658203f,0.08946844935417175f,0.17319494485855103f,-0.3548906445503235f,0.4122363030910492f,0.28641819953918457f,0.18554691970348358f,0.14541564881801605f,0.4110986292362213f,-0.45408642292022705f,-0.2165788859128952f,0.27305224537849426f,-0.047836560755968094f}, -{-0.2806110680103302f,0.40231046080589294f,-0.25313520431518555f,0.5885722637176514f,0.036378175020217896f,-0.22483457624912262f,-0.6083595752716064f,-0.08570799231529236f,0.30782198905944824f,-0.6609525084495544f,-0.08430586755275726f,-0.4229513108730316f,-0.23955631256103516f,-0.19798928499221802f,-0.2544192671775818f,-0.6755768060684204f}, -{0.5131750702857971f,0.294185608625412f,-0.3519742488861084f,0.19928856194019318f,-0.3015052080154419f,-0.024108221754431725f,-0.23793454468250275f,-0.019414573907852173f,-0.42064279317855835f,0.5497127175331116f,-0.10041175037622452f,0.001658409833908081f,-0.023390205577015877f,0.3993215262889862f,0.15392538905143738f,-0.18064595758914948f}, -{-0.2636679708957672f,-0.02554568648338318f,-0.3260969817638397f,1.400650143623352f,-0.38453540205955505f,-3.0441176891326904f,-1.0309864282608032f,0.12387624382972717f,1.327842354774475f,0.8234207034111023f,1.1026571989059448f,-0.32796353101730347f,-1.0295908451080322f,0.049302369356155396f,-0.27088475227355957f,-1.773733377456665f}, -{0.15550771355628967f,0.33974209427833557f,0.33083590865135193f,0.21785464882850647f,-0.14358049631118774f,-1.6028454303741455f,-0.49285537004470825f,-0.3003333508968353f,0.8130767941474915f,-0.45922738313674927f,0.9424108266830444f,-0.2890920341014862f,-0.968544602394104f,0.36012205481529236f,0.048003822565078735f,-0.24998000264167786f}, -{-0.25820738077163696f,0.35453304648399353f,-0.11379697918891907f,0.07942168414592743f,0.041274964809417725f,-0.33757007122039795f,-0.06726410984992981f,0.0019084513187408447f,0.024072596803307533f,-0.35254228115081787f,0.03284132853150368f,-0.3197441101074219f,-0.3433385193347931f,-0.30194157361984253f,-0.4068881571292877f,-0.1724976897239685f}, -{-0.14576366543769836f,0.22098979353904724f,-0.13502129912376404f,0.1006976068019867f,0.12987366318702698f,0.11301741003990173f,0.2711336314678192f,-0.3632148504257202f,-0.13619378209114075f,0.16938945651054382f,0.24499371647834778f,0.39862415194511414f,0.3811538517475128f,-0.23332324624061584f,0.011877655982971191f,-0.23860150575637817f}, -{-0.2709399461746216f,-0.006022721529006958f,0.0457797646522522f,-0.38090792298316956f,-0.03321319818496704f,-0.4148826003074646f,0.17873415350914001f,-0.20421427488327026f,-0.050184011459350586f,0.12480869889259338f,-0.20706263184547424f,0.3545852601528168f,-0.3647043704986572f,0.42127421498298645f,-0.39804020524024963f,-0.2870290279388428f}, -{0.33538809418678284f,0.3494977056980133f,0.3954955041408539f,0.3170476257801056f,0.0033026933670043945f,0.3035760819911957f,-0.18492193520069122f,-0.11795541644096375f,0.3487861454486847f,-0.32520344853401184f,0.3952759802341461f,-0.15237495303153992f,0.0820283591747284f,-0.3793424367904663f,0.2430708110332489f,0.24988999962806702f}, -{-0.37207356095314026f,-0.180922269821167f,-0.15798500180244446f,0.36838704347610474f,-0.37393757700920105f,0.44713646173477173f,0.025694025680422783f,-0.2947862446308136f,-0.39739224314689636f,0.1606505811214447f,-0.09350364655256271f,-0.2837170362472534f,0.4245411455631256f,-0.19196075201034546f,-0.15901821851730347f,0.014467512257397175f}, -{-0.28947749733924866f,0.26506301760673523f,-0.2018718123435974f,0.5882180333137512f,0.07545611262321472f,-1.3561453819274902f,-0.4799374043941498f,-0.21416273713111877f,0.24524515867233276f,0.2077748328447342f,0.7775342464447021f,-0.25593626499176025f,-0.112045519053936f,0.27643296122550964f,-0.23556609451770782f,-0.41434746980667114f}, -{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.46387147903442383f,0.3827712833881378f,0.12081471085548401f,-0.26810991764068604f,0.29976895451545715f,0.5951269268989563f,-0.09479555487632751f,0.31089308857917786f,-0.5688030123710632f,-0.46812617778778076f,0.21434427797794342f,-0.11613789200782776f,-0.19970247149467468f,-0.02543884515762329f,0.22754064202308655f,0.0740114152431488f}, + {-0.36079341173171997f,0.5496202707290649f,-0.6524567604064941f,-1.0138130187988281f,-0.7639057636260986f,0.5781964063644409f,0.3332441747188568f,0.3036012351512909f,-0.2405819296836853f,0.04891335964202881f,-0.11870327591896057f,0.4001283347606659f,-0.533208429813385f,0.9845144152641296f,0.32505926489830017f,-0.19595709443092346f}, +{0.047732532024383545f,0.017954785376787186f,-0.18629395961761475f,-0.9162130951881409f,-0.43290695548057556f,-4.281400680541992f,-0.3198729455471039f,0.06247803568840027f,-0.19349214434623718f,-0.9508686065673828f,0.2572092115879059f,-0.41319137811660767f,-0.35956844687461853f,-0.5297766327857971f,0.10103966295719147f,-0.7109990119934082f}, +{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.05632366985082626f,-1.3186177015304565f,-0.9530683755874634f,-0.49597063660621643f,0.2564902603626251f,0.20021501183509827f,0.07002416253089905f,-0.4060443043708801f,-0.4593014717102051f,0.13192829489707947f,0.41021624207496643f,-0.2266009896993637f,0.25329798460006714f,0.28113701939582825f,-0.15740571916103363f}, +{-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.02029903419315815f,-2.5072414875030518f,-12.973404884338379f,0.2337467223405838f,1.0865919589996338f,-0.18732719123363495f,0.22384825348854065f,-0.850281298160553f,-0.4489060342311859f,-0.23735009133815765f,0.05998014658689499f,0.23774290084838867f,0.08863037824630737f,0.5211813449859619f,-1.1956897974014282f}, +{0.4110594093799591f,0.2715781033039093f,-0.12724249064922333f,0.37246426939964294f,-0.06906148046255112f,-0.05251416191458702f,-0.08670487999916077f,-0.25336313247680664f,-0.030661463737487793f,-0.06259563565254211f,-0.1344406008720398f,0.35313835740089417f,0.13369451463222504f,0.2011522799730301f,0.3126353323459625f,-0.3391006588935852f}, +{-0.40892091393470764f,0.04420051723718643f,-0.26215535402297974f,0.25968697667121887f,0.4493691027164459f,-0.16038022935390472f,-0.23312048614025116f,-0.390264093875885f,0.28059282898902893f,-0.1559126079082489f,-0.14134526252746582f,-0.0003446042537689209f,-0.17052586376667023f,-0.4737553000450134f,0.08030081540346146f,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.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.3123319149017334f,0.10377500206232071f,-0.044353384524583817f,-0.2320195883512497f,0.12762269377708435f,-0.08742031455039978f,0.05785742402076721f,-0.07219423353672028f,-0.2943510413169861f,0.1268840730190277f,-0.30447322130203247f,-0.044554103165864944f,-0.20284022390842438f,0.5049844980239868f,0.23406195640563965f}, +{-0.408692330121994f,0.7442746162414551f,-0.3166918158531189f,-0.5923694968223572f,-2.5536251068115234f,2.459355354309082f,0.03285527229309082f,0.38763079047203064f,-0.20705322921276093f,-0.25883403420448303f,0.12809070944786072f,0.03996849060058594f,1.5557342767715454f,2.810499429702759f,0.883807361125946f,-0.5292647480964661f}, +{-0.2991822361946106f,0.3794580399990082f,-0.07897943258285522f,-0.05932474136352539f,-0.019097916781902313f,0.10188531875610352f,-0.11253207921981812f,0.34576353430747986f,0.04814547300338745f,-0.35770976543426514f,-0.044228196144104004f,-0.36229726672172546f,0.015840977430343628f,-0.13475483655929565f,0.36124154925346375f,-0.16869547963142395f}, +{-0.2675279378890991f,-0.4076881408691406f,0.6109089851379395f,1.124742865562439f,0.791110098361969f,-1.8034776449203491f,-0.32875844836235046f,-0.31893211603164673f,-0.6889935731887817f,-1.1343306303024292f,-0.5256567001342773f,-0.8404866456985474f,1.0291988849639893f,-1.3514559268951416f,0.12213380634784698f,0.17103822529315948f}, +{-0.015470266342163086f,-0.23503242433071136f,0.13451209664344788f,0.36471807956695557f,-0.08753460645675659f,-0.20316985249519348f,0.05196094512939453f,-0.008358269929885864f,-0.4239840805530548f,-0.38441595435142517f,0.13179203867912292f,-0.11511552333831787f,0.07671336829662323f,0.1646096110343933f,0.19001242518424988f,-0.29890790581703186f}, +{0.1863725483417511f,-0.07918193191289902f,-0.8252384066581726f,-36.685184478759766f,1.862860083580017f,1.8086168766021729f,0.04860696196556091f,0.17769548296928406f,-0.32842522859573364f,-0.40967434644699097f,-0.3929237127304077f,-0.0008496989612467587f,2.3736817836761475f,1.629492998123169f,-0.45149895548820496f,-0.32196617126464844f}, }; -const float hout[16] = { -0.158200204372406f,-0.17660260200500488f,-0.05137401819229126f,-0.5410199761390686f,-0.20271384716033936f,0.35903048515319824f,0.3810136020183563f,0.4165375232696533f,-0.4397028386592865f,0.12780319154262543f,-0.3604712188243866f,0.5489715337753296f,0.19251443445682526f,0.3525826036930084f,-0.480579137802124f,0.23442186415195465f }; - -const float b1[16] = { -0.31192219257354736f,0.268393874168396f,1.7755248546600342f,-0.407010555267334f,-0.8632325530052185f,1.3653104305267334f,-0.8388656973838806f,-0.8200502991676331f,-0.2854437828063965f,-1.6282782554626465f,0.8953557014465332f,-0.12085551768541336f,-1.5856122970581055f,-0.6190592050552368f,0.3934020400047302f,-0.36230528354644775f }; - -const float b2[16] = { -0.40527141094207764f,-1.3118138313293457f,0.9577730298042297f,1.5444650650024414f,0.5990768074989319f,-0.10386185348033905f,0.4417823553085327f,0.181562602519989f,-0.16907061636447906f,-1.6486880779266357f,-0.22539173066616058f,-2.15936541557312f,1.5229467153549194f,0.11918190121650696f,-0.6625781655311584f,0.4921003580093384f }; - -const float b3[16] = { 0.6422635316848755f,-0.1894310712814331f,0.21861673891544342f,0.1256403774023056f,-0.4563063681125641f,-0.5133413076400757f,1.4254883527755737f,-0.7025120258331299f,0.6852500438690186f,-0.6245395541191101f,-0.17192035913467407f,-0.7519525289535522f,-0.22238163650035858f,0.17018213868141174f,-0.45795938372612f,1.070515513420105f }; - -const float bout[1] = { 0.5118825435638428f }; +const float hout[16] = { 0.45773375034332275f,0.3443804383277893f,-0.43964359164237976f,-0.21056394279003143f,0.19662600755691528f,0.7040731906890869f,0.0030125975608825684f,0.15066689252853394f,0.10095822811126709f,-0.13003124296665192f,0.18801097571849823f,0.0785079076886177f,-0.15748845040798187f,0.1868625432252884f,0.18598346412181854f,-0.9022102355957031f }; + +const float b1[16] = { 0.7107149362564087f,1.0883506536483765f,-1.7145336866378784f,0.09724511206150055f,1.4542453289031982f,1.417521595954895f,-0.058932315558195114f,0.9398505687713623f,0.4389953017234802f,-0.9609658718109131f,0.8672975301742554f,1.5156910419464111f,-0.3718140721321106f,-0.886523962020874f,-1.087764859199524f,2.5278995037078857f }; + +const float b2[16] = { -0.4577406942844391f,-0.4344789981842041f,-1.4564176797866821f,-0.6435210704803467f,-0.6939148902893066f,-0.16397996246814728f,-0.013260572217404842f,-0.43840786814689636f,-1.20063054561615f,-1.912178635597229f,-0.1346415877342224f,0.10342646390199661f,-0.23722384870052338f,0.9154923558235168f,-0.1802087128162384f,1.0650097131729126f }; + +const float b3[16] = { -1.963319182395935f,-0.7180035710334778f,0.7040019035339355f,-0.4437018930912018f,-0.7515134811401367f,1.0377838611602783f,-0.45353031158447266f,-0.6562485098838806f,0.04508165270090103f,0.06766403466463089f,-0.29913392663002014f,-0.09212813526391983f,-1.5836485624313354f,0.42195138335227966f,-1.3884198665618896f,-0.511356770992279f }; + +const float bout[1] = { 0.09115694463253021f }; /////////////////////////////////////////////////////////////////////////////////////////////RL float input_RL[num_input_RL] = { 0.0f }; @@ -1037,8 +1036,8 @@ ind = ind + 1; } // input_NN[ind] = torq.sen / 10000.0f * 8.0f + 0.5f; - input_NN[ind] = torq.sen / 10000.0f + 0.5f; - ind = ind + 1; +// 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 * 8.0f + 0.5f; // input_NN[ind] = (f_future[time_interval*i+time_interval] - torq.sen)/10000.0f + 0.5f;