thanks for trying to understand.
If now I look at input_transformed/*mif, then some volumes are very wrong (as debribe before) so I guess this is the second mrregister path that go wrong (although it ended without error and produce the file initial_template0.mif)
then the thrid mrregister get an error for the subject 015_VS (its input_transformed has a 90 ° tilt wrong)
the out for gd.csv
not sure if this is the best way to share
it was to big to publish so I put only the firsts and the lasts lines
#iteration,feval,cost,stepsize,x_1,x_2,x_3,x_4,x_5,x_6,x_7,x_8,x_9,x_10,x_11,x_12,g_1,g_2,g_3,g_4,g_5,g_6,g_7,g_8,g_9,g_10,g_11,g_12
0,1,1968.250910537191,0.0009290824116225645,0.04270709839275505,-0.2943247272939078,0.45752901344304597,17.601205487076975,0.50146553451918985,0.19831828976813246,0.16640267316001642,-11.57127937245216,-0.44506508657116889,0.33636608799280204,0.26459084412274642,4.2609603616476868,-419.78181259552474,210.18943571939312,-119.24933762954261,-2.6644907988680462,-220.38440211791709,-698.17727502288892,-104.48333484675321,2.7430378853199033,174.11523742814242,-216.41089409225751,-547.50013421360745,-3.5792162090188975
0,2,1906.3599076072296,0.00012965899733938653,0.047234121461950218,-0.29648150901318848,0.45939301868622129,17.601713329643449,0.50490129341339218,0.21075630947528406,0.17112142050678072,-11.502873613008262,-0.44586103265329935,0.34325127214098167,0.27481431709592513,4.1409003801324253,-0.12559499956204553,0.060039170724714111,-0.034293567102684323,-2.4987033050772238,-0.063224737104974935,-0.20512376076895142,-0.031670541203372995,2.930925927716264,0.049400577947889268,-0.064227696916140081,-0.16109531713593894,-3.423941114307095
1,3,1906.2885112248243,0.00012965899733938653,0.047239122700994715,-0.29648371145952845,0.45939498576682003,17.602044004553001,0.50490489374880965,0.21076976883563875,0.17112669110590512,-11.502909962187172,-0.4458617751587316,0.34325881192579721,0.27482531895166068,4.1409163453243156,-418.65143081849857,200.14846697381861,-114.31342354804865,-2.4992324793611935,-210.72304916533741,-684.05114279093016,-105.62449070995139,2.9338671377613754,164.62442262532855,-214.05079498286733,-536.91794781943975,-3.4229093350629416
2,4,1847.3397659776331,0.10550009723152279,0.051260001558601317,-0.29828114985384163,0.46102945593869393,17.870789398347661,0.50788451933176637,0.22161941826483805,0.17540824464793212,-11.531180757226686,-0.44647045370361749,0.3494264930396388,0.28376001407839085,4.1520304921173636,-413.79777115909474,184.81822928869769,-109.27709337714241,-2.3375466402291472,-203.08449743507828,-663.44348203955769,-110.2212915144983,3.0268150144711017,159.42101752993466,-212.8294513002287,-518.77598106923415,-3.1573659797025471
3,5,1738.7764905391693,0.83469288494318672,0.05915227505621358,-0.30147171678687557,0.4642281199343527,18.37581412308851,0.51383653479442915,0.24240954399801701,0.18414089350414986,-11.613128823614792,-0.44768466760868036,0.36180146053994316,0.30093579406766091,4.142675174228776,-405.15390824858827,155.05258156109176,-99.279589321302183,-2.0922402839474898,-191.2681706126225,-624.14703024868891,-114.72227507515933,3.0357413397074149,147.87954259071722,-214.13056025315896,-482.79311016372282,-2.5872181169570108
4,6,1644.3881178643637,0.82564633412203159,0.067079609682256056,-0.30389001097449242,0.46720303899295468,18.824060475961815,0.51977708935134204,0.26206934287663475,0.19317038835728984,-11.726679626319655,-0.44879771944892816,0.37430903453392805,0.31700275695085844,4.073734525273637,-388.37788630139676,125.24236004343192,-88.20826590147577,-1.697060798365257,-186.13338195013549,-571.18078452813029,-116.15396584913566,2.8585882596995713,137.10178267086383,-208.73293932491458,-432.08712571640353,-1.8833427403803058
5,7,1588.3704179272961,0.56673695777151345,0.072551399586704896,-0.30505573139116254,0.46899807654041281,19.074101169447701,0.52397195852114598,0.27464193798803682,0.1994694839887397,-11.819980724992515,-0.44954410381876686,0.38274473824473987,0.32705458092186923,3.9864061700370135,-375.83809119716778,104.19218898460534,-83.074500941605365,-1.4044765139559441,-185.30884587217571,-528.02822122302257,-112.87229814512079,2.5278039741257299,130.40056284933721,-201.87665472367704,-399.25277312352387,-1.4268163006379857
6,8,1515.1110523599148,0.44309712048049449,0.081005660650746533,-0.30629732561881201,0.4716821420794759,19.392705358506973,0.53076680235885998,0.29294523759614222,0.20927778014156317,-11.951184583251074,-0.45074249807762939,0.39560142587626468,0.34174000591619874,3.8192587115196028,-353.04470759341172,74.873759864082601,-71.856446174926901,-1.0539797989808311,-180.45950479793581,-435.67183203274681,-98.975292987648473,1.7405562633176175,118.39642759552044,-184.14609005820861,-336.67199384275534,-0.85251625978004475
7,9,1468.8557344423173,0.37076167227760742,0.088080301900097344,-0.30665400822067107,0.47362519492800115,19.571929638646761,0.53647369257165889,0.30571436799761165,0.21694685243065004,-12.001343659202778,-0.45185949120321012,0.40540062465935978,0.35217496596294107,3.6697592889682475,-332.93924919725976,51.91481663082309,-68.485653478541138,-0.80741013733943134,-173.6477908025407,-350.11414909828699,-80.168539513535848,0.90021227183074859,107.44954138329719,-157.41855199386598,-289.64534697958328,-0.54645706238172054
8,10,1420.7034433805909,0.25832289180513451,0.097707842336486536,-0.30639884033867176,0.47630584632517847,19.731342784010458,0.54417368293832213,0.32005455006346245,0.22661911788745176,-11.957415982581301,-0.45362312064811217,0.41721601706643835,0.36455277878422587,3.4918553183241143,-313.41037778793998,29.118967464289945,-63.045005760082816,-0.64899223642939297,-160.00544158326741,-256.23791923306476,-49.825026124565426,-0.079498497087990172,96.877864676033312,-124.8757735381797,-227.40772921317435,-0.20868901143375373
9,11,1388.0537620443915,0.23300816126674184,0.10633834356332282,-0.30555442547281264,0.47858974250483549,19.799183239497754,0.55067131851456819,0.32940850086034357,0.23379956946865982,-11.787197892280757,-0.45541684948990679,0.42574033363849961,0.37295040204763497,3.3584187978365918,-298.9516987934407,15.827244050212895,-58.217218349535436,-0.52290133072995049,-147.76271171005448,-201.58590480566357,-25.740043780616318,-0.61521680172227811,92.320923842496228,-92.990581737454704,-182.85308135544645,0.0074017544118179131
10,12,1347.060644894681,0.38454305013494555,0.12010786681452382,-0.30378796735680441,0.48209641874968368,19.835275858342488,0.56078920486329309,0.3412234051967995,0.24359346845132879,-11.393282226349243,-0.45871392480329021,0.43675535673935584,0.3834167751669616,3.1637985080145379,-276.28098372820421,-1.9216301818806598,-52.125221394434476,-0.27805367242967882,-127.01474423567058,-138.57123258814292,6.4443742411202862,-1.1589876932979499,84.288060602471802,-59.483848783741649,-122.31021656695589,0.063247644081456611
11,13,1316.8965955566464,0.73647835835071285,0.13275771134781006,-0.30161344574370741,0.48509529676973046,19.790285683500599,0.56955646413972127,0.34846883301178549,0.25012171569979363,-10.916329720071463,-0.46200787081303341,0.44381299069190316,0.38896083290268246,3.0584457152526165,-263.79528707710506,-6.369076285447643,-48.152628935498974,-0.20238919130357177,-113.15578412072712,-113.05234798530721,26.827515221029099,-1.3239289936782679,80.495191292458074,-31.227073508618567,-92.925015875727752,0.17622227945584976
12,14,1297.2999703841147,2.2897365476528497,0.14214054974878956,-0.30002867907876513,0.4872188924701098,19.736505711288757,0.57584235951450857,0.35268129274035592,0.25378592420468338,-10.525412368252463,-0.46463975026008164,0.44740652939647241,0.39147607682860036,2.9807418934509462,-255.15611679037366,-8.4253278978259072,-44.299730271762456,-0.16951307760427217,-105.22091259112608,-105.24644277316096,40.143941444067941,-1.3539052081758385,77.470271035611717,-14.981404816210457,-78.33379224252694,0.091851385429330829
365,367,979.74852815200563,1.0655304618275199,-0.90555576181430775,-0.19760932349320351,0.67959188455009356,6.5365425090779645,0.28354416978711566,-0.0041049518025179574,0.78635179698613833,-9.4535788459599459,-0.17357221991510238,0.74667490372419121,-0.2459415570007524,-1.6619539317135259,58.232003528068141,-92.649173454345544,119.9934769719665,1.4906673651341948,150.3755823074313,12.126880262042121,-28.579165788168808,-0.29784551654426178,-151.65930269592567,9.3014028328672502,18.215512058239309,0.49219956075979787
366,368,976.68720299123493,0.71502449224442233,-0.91995432236873054,-0.19083699172096369,0.67489550178260382,6.5457851155222482,0.27101237758584279,-0.0077906921037926499,0.79314046398599503,-9.5111282838907698,-0.15922621436602999,0.7495108466921121,-0.25362792473796297,-1.6870561434696132,62.170318064012662,-90.796014895826801,116.4706406900939,1.4912637216439728,153.43514692446772,10.227190810362103,-27.766388342906378,-0.34601801117806613,-151.97288480633131,10.42257682278051,11.515165747660523,0.47992925739285236
367,369,971.18501166674946,1.3901901325791379,-0.93437642199177784,-0.18415806344899505,0.67045320791464569,6.5606640780984353,0.25837803218319866,-0.01096260465190451,0.79953627899440738,-9.5532110564641748,-0.14482793168064334,0.75203452888674094,-0.26068621127585379,-1.7093793999412668,60.817356269595919,-85.630298207864186,109.24914121058808,1.5293172748840753,160.35520204778399,9.0880825378413554,-24.547878457175063,-0.31188778422421698,-147.93193277977866,6.1160942941989473,9.9341199431147817,0.46313759172878738
368,370,966.43478472329366,1.0545460088639018,-0.95579477888707765,-0.17436495002715854,0.66433000518219165,6.5905486851452206,0.23835866677808748,-0.01535617388808623,0.80893093892170898,-9.6193838350865839,-0.12231418611245276,0.75589388014663283,-0.2714163722854766,-1.7576535749621953,69.296907271582128,-78.569699804609257,109.88259342139108,1.5708960269552905,168.72769547962591,6.1412029746479302,-20.264769836110222,-0.29097585846331431,-163.98877157830435,13.466325517932681,9.8979663695284117,0.38510781107882985
369,371,961.33039628681536,1.0606224787471481,-0.97957540531810483,-0.16488301090495833,0.65879007901295372,6.6566451103345798,0.21593959164819912,-0.019527268691165431,0.81815319421835264,-9.653874476079956,-0.096781724558310953,0.75891773813812613,-0.28231122723837399,-1.8162304167064007,71.336301892303368,-79.348525788972182,94.78109844652127,1.5804370542812829,173.1467316482854,-0.79292817626036527,-20.893926331784076,-0.28117879298046028,-176.40491515942924,15.220496683507928,3.0404048937565129,0.32151480373626734
370,372,955.14204814515426,1.6082045613459661,-0.99835452653311019,-0.15798230536747249,0.65567173028877757,6.7312362896387459,0.19760275685060802,-0.021840992017532063,0.82534331163456498,-9.6598777254159032,-0.075692394384512834,0.76087642319171933,-0.29005657593657702,-1.8680374407710412,73.515522984114753,-73.123470954230356,93.574931011085738,1.5195490278271966,182.54105657641782,-2.1280713011071994,-16.187795029163638,-0.31145959469649309,-187.73562264978358,18.577332369121134,0.82762013878604568,0.36198961105546468
371,373,951.7150964323655,1.2351679977195789,-1.0133764729745836,-0.15288519235549014,0.65364848122770269,6.790069167870592,0.18235538100151763,-0.023466702779819909,0.83073729823629416,-9.6536157897557615,-0.058151141171829436,0.76205118834573227,-0.29604801674462827,-1.9193387317448116,86.199749102885107,-67.141620574433702,86.094751249897243,1.6317770868273553,197.00751535698063,-8.1061915533057949,-14.247836197376351,-0.27717280413421763,-195.70312605085641,20.961755178255693,-0.184544088673956,0.28028672791950404
372,374,948.46005711534076,0.58426993763130475,-1.0290668354631167,-0.14857946939165645,0.65276386246086049,6.864511344565611,0.16682526636831546,-0.024637108091498373,0.83574910334107944,-9.637988689636245,-0.040310435722020088,0.76299372007718225,-0.30181577806975607,-1.9745282514972977,91.52958181166926,-64.952067494279717,80.153269875608004,1.7343311948314379,208.42624771556612,-8.9929667657603503,-9.4565426109238118,-0.19193142003452918,-212.37611747957484,24.247620532693823,-2.3138385984734331,0.35177044904260479
373,375,946.94456579785492,0.65084751647048167,-1.0478860951741613,-0.14403966896658604,0.652650060200889,6.9550399532416591,0.1479561814011616,-0.025834408620362577,0.84140051673100824,-9.6332783356016378,-0.018533514741338526,0.76374778598177451,-0.30849157451987042,-2.0679120570953415,113.99686985454333,-59.427471851281773,75.653342611150009,1.6885645841495744,242.39280915358933,-13.193758584234669,-1.891956718624368,-0.26088127427336433,-241.80469158168793,32.493080436355932,-2.3359731585996029,0.34660601587404971
374,376,935.58126519209736,1.5997626875964832,-1.0763531832429341,-0.13917336255108947,0.65504361731443261,7.0968515402635539,0.12072009009109735,-0.027285956288311961,0.84867146434278851,-9.583761545361142,0.013013953476490855,0.76434706239542105,-0.31816931076807814,-2.2062411525482903,151.18328158325212,-54.564310890958595,58.465418809073391,1.6356769115126886,311.5310044020946,-24.127126727600778,7.538836752654146,-0.42186361470694417,-306.68397543003556,40.559164684054302,-9.2499248586512479,0.25310939453469189
375,377,0,1.0749394262347991,-nan,-nan,-nan,-nan,-nan,-nan,-nan,-nan,-nan,-nan,-nan,-nan,0,0,0,0,0,0,0,0,0,0,0,0