<html>Dear Karssen,<br /><br />>> What is the best course of action for supporting probabel on big endian?<br />>> Should *.fvi, *.fvd files allways be in little endian format (than<br />>> DatABEL needs to be changed to always create little endian files)?<br />>> Or can *.fvd, *.fvi files be replaced with big endian files for big<br />>> endian build?<br /><br />>I would say that ideally the files need only to be created once and then<br />>usable on all systems. Especially since these files are usually large<br />>and converting from text format to .fvi/.fvd takes quite a while.<br /><br />If I had to change some values in text format, would I have to generate again fvd/fvi files?<br />Does one when working with ProbABEL has to change those files often?<br />If we do byte-swap on the run for every data in the fvd/fvi file would that be also time consuming?<br />I understand that user then do not need to wait files to generate again on big endian,<br />but same task (run) will last longer on big-endian machine than on little-endian one?<br /><br />>This, however, would require diving into the filevector and the DatABEL<br />>code (filevector or libfilevector is the name of the 'backend' code in<br />>which the .fvd/.fvi files are 'defined'; both DatABEL and ProbABEL use<br />>that code when dealing with .fvi/.fvd files). I don't have very much<br />>experience with either code base, but could probably have a look and<br />>give you some pointers.<br /><br />I tried to work around this and got some results, but a I did not manage<br />to find every place in code where endian swap is needed.<br />I am currently busy with other work, but i will soon look at this again.<br /><br />>Jurica, can you tell us a bit more about why you are using a MIPS<br />>machine for your work with ProbABEL? And do you think it would be a<br />>common task to move these files between machines with different<br />>architectures at your site?<br /><br />I work on supporting mips/mipsel for Debian sid.<br />I have access to mips and mipsel boards and can help with bigendian support.<br />But I do not use ProbABEL actively.<br /><br />>Maybe a converter from big to little and vice versa would be the easiest<br />>solution? I guess such a conversion can be done rather quick. The<br />>downside would be that it (at least temporarily) requires double the<br />>disk space.<br />>Such a converter could be part of the fvutils and/or of DatABEL, for<br />>example.<br /><br />Maybe this could be a good solution, presuming that this would be faster then just converting from text to fileVector format?<div style="text-align: left;">I will have to look closer how data is converted and writen from text to fvd/fvi in order to be able to convert them to different endian.</div><br />There is also a option to always create a fvd/fvi in both endian formats,<br />or to create some universal file that have data in both endians inside.<br /><br />Regards,<br />Jurica<br /><br />-------- Original Message --------<br />Subject: Re: [GenABEL-dev] probabel big endian support<br />Date: Saturday, April 26, 2014 22:17 CEST<br />From: "L.C. Karssen" <lennart@karssen.org><br />To: genabel-devel@lists.r-forge.r-project.org<br />References: <896-53591700-f-3be4eec0@227853676><br /> <blockquote type="cite" cite="535C1462.9090502@karssen.org">Dear Jurica,<br /><br />On 24-04-14 15:52, Jurica Stanojkovic wrote:<br />> Dear list,<br />><br />> I have tried building package probabel on mips big endian.<br /><br />That is great to hear! As far as I know, none of the current developers<br />have access to such a machine.<br /><br />> It looks like that inputfiles/*.fvd and inputfiles/*.fvi are created on> little endian machine and are not working on big endian ones.<br /><br />That is correct, we found out<br /><br />><br />> I have tried to create them on big endian mips, and replace ones that<br />> came with source package with the ones that I have created.<br />> The package was built with new files without an error.<br /><br />That is good news. So GenABEL and DatABEL work on big-endian machines.<br /><br />><br />> I used following command to create files:<br />> library(GenABEL)<br />> library(DatABEL)<br />> fvdose <- mach2databel(imputedg="./checks/inputfiles/test.mldose",<br />> mlinfo="./checks/inputfiles/test.mlinfo",<br />> outfile="./checks/inputfiles/test.dose")<br />> fvprob <- mach2databel(imputedg="./checks/inputfiles/test.mlprob",<br />> mlinfo="./checks/inputfiles/test.mlinfo",<br />> outfile="./checks/inputfiles/test.prob", isprob=TRUE)<br />> mmdose <-<br />> mach2databel(imputedg="./checks/inputfiles/mmscore_gen.mldose",<br />> mlinfo="./checks/inputfiles/mmscore_gen.mlinfo",<br />> outfile="./checks/inputfiles/mmscore_gen.dose")<br />> mmprob <-<br />> mach2databel(imputedg="./checks/inputfiles/mmscore_gen.mlprob",<br />> mlinfo="./checks/inputfiles/mmscore_gen.mlinfo",<br />> outfile="./checks/inputfiles/mmscore_gen.prob", isprob=TRUE)<br />><br />> I am new to ProbABEL, GenABEL, DatABEL so could someone please help me<br />> with following questions:<br />><br />> What is the best course of action for supporting probabel on big endian?<br />> Should *.fvi, *.fvd files allways be in little endian format (than<br />> DatABEL needs to be changed to always create little endian files)?<br />> Or can *.fvd, *.fvi files be replaced with big endian files for big<br />> endian build?<br /><br />I would say that ideally the files need only to be created once and then<br />usable on all systems. Especially since these files are usually large<br />and converting from text format to .fvi/.fvd takes quite a while.<br /><br />This, however, would require diving into the filevector and the DatABEL<br />code (filevector or libfilevector is the name of the 'backend' code in<br />which the .fvd/.fvi files are 'defined'; both DatABEL and ProbABEL use<br />that code when dealing with .fvi/.fvd files). I don't have very much<br />experience with either code base, but could probably have a look and<br />give you some pointers.<br /><br />><br />> Is it necessary to be able to use *.fvd *.fvi files created on a<br />> different endian system?<br /><br />On the other hand, how often will people transfer these files to<br />machines of different architectures?<br /><br />Jurica, can you tell us a bit more about why you are using a MIPS<br />machine for your work with ProbABEL? And do you think it would be a<br />common task to move these files between machines with different<br />architectures at your site?<br /><br />Maybe a converter from big to little and vice versa would be the easiest<br />solution? I guess such a conversion can be done rather quick. The<br />downside would be that it (at least temporarily) requires double the<br />disk space.<br />Such a converter could be part of the fvutils and/or of DatABEL, for<br />example.<br /><br />><br />> I am willing to work on adding big endian support and I will appreciate> any help in determining the right course of action in resolving this<br />> problem.<br /><br />Thank you for your time and willingness to help! It is very much<br />appreciated. We're a small group of developers, but we'll try to help as<br />much as we can.<br /><br /><br />Best,<br /><br />Lennart.<br /><br />><br />> Regards,<br />> Jurica<br />><br />><br />> _______________________________________________<br />> genabel-devel mailing list<br />> genabel-devel@lists.r-forge.r-project.org<br />> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/genabel-devel<br />><br /><br />--<br />*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*<br />L.C. Karssen<br />Utrecht<br />The Netherlands<br /><br />lennart@karssen.org<br />http://blog.karssen.org<br />GPG key ID: A88F554A<br />-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-<br /> </blockquote><br /> </html>