Back to the main page.

Bug 639 - fieldtrip-lite should exclude the templates and the externals

Reported 2011-05-04 13:59:00 +0200
Modified 2012-04-11 16:48:38 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Windows
Importance: P1 normal
Assigned to: Robert Oostenveld
Depends on:
See also:

Robert Oostenveld - 2011-05-04 13:59:03 +0200

Robert Oostenveld - 2011-11-30 17:24:20 +0100

Hoi Boris, hier moeten we het even over hebben. Hoe kunnen we de "lite" versie lichter maken, en toch voldoende functioneel houden? Robert

Robert Oostenveld - 2012-03-11 12:25:04 +0100

at this moment the release script is the following. fieldtrip excludes all .svn and all test directories fieldtrip-lite also excludes all *.mat files. ----------------------------------------------------------------- #!/bin/sh TODAY=$(date +%Y%m%d) BASEDIR=$HOME/fieldtrip/release TRUNK=$BASEDIR/trunk MD5FILE=$BASEDIR/.tarmd5-release-ftp cd $TRUNK && svn update cd $HOME/fieldtrip/release || exit 1 rsync -ar --copy-links --delete --exclude .svn --exclude test $TRUNK/ release-ftp || exit 1 CURRMD5=$(tar cf - release-ftp |md5sum |awk '{print $1}') LASTMD5=$(cat $MD5FILE) if [ "x$CURRMD5" = "x$LASTMD5" ] then # the current release has not been updated compared to the previous exit 0 else # the current release is an updated version echo $CURRMD5 > $MD5FILE mv release-ftp fieldtrip-$TODAY zip -r daily/fieldtrip-$ fieldtrip-$TODAY zip -r daily/fieldtrip-lite-$ fieldtrip-$TODAY -x '*.mat' mv fieldtrip-$TODAY release-ftp rm -f daily/ ln daily/fieldtrip-$ daily/ rm -f daily/ ln daily/fieldtrip-lite-$ daily/ cp daily/fieldtrip-$ /home/common/matlab/fieldtrip/data/ftp/fieldtrip-$ cp daily/fieldtrip-lite-$ /home/common/matlab/fieldtrip/data/ftp/fieldtrip-lite-$ fi

Robert Oostenveld - 2012-03-11 12:51:16 +0100

I took the two versions of 20120309 and looked at their size roboos@mentat001> du -hs * 309M fieldtrip-full-20120309 196M fieldtrip-lite-20120309 So lite is 100MB smalled, but compared to full only 30%. Looking into the lite version roboos@mentat001> du -hs fieldtrip-lite-20120309/* | grep -v '\.m' | grep M 1.3M fieldtrip-lite-20120309/engine 100M fieldtrip-lite-20120309/external 5.1M fieldtrip-lite-20120309/fileio 1.4M fieldtrip-lite-20120309/forward 6.8M fieldtrip-lite-20120309/multivariate 5.3M fieldtrip-lite-20120309/peer 2.2M fieldtrip-lite-20120309/private 1.6M fieldtrip-lite-20120309/qsub 4.0K fieldtrip-lite-20120309/README 55M fieldtrip-lite-20120309/realtime 2.4M fieldtrip-lite-20120309/src 8.7M fieldtrip-lite-20120309/template 1.6M fieldtrip-lite-20120309/utilities external is 100MB, realtime is 55MB. Items to exclude could be peer, engine and qsub, because they are for advanced users only. Idem multivariate and realtime. Looking in more detail into "external" shows these large ones roboos@mentat001> du -hs fieldtrip-lite-20120309/external/* | grep M 1.3M fieldtrip-lite-20120309/external/afni 2.6M fieldtrip-lite-20120309/external/bci2000 7.9M fieldtrip-lite-20120309/external/dmlt 33M fieldtrip-lite-20120309/external/fns 7.7M fieldtrip-lite-20120309/external/iso2mesh 1.2M fieldtrip-lite-20120309/external/neuroshare 4.0K fieldtrip-lite-20120309/external/README 11M fieldtrip-lite-20120309/external/simbio 14M fieldtrip-lite-20120309/external/spm2 13M fieldtrip-lite-20120309/external/spm8 4.0M fieldtrip-lite-20120309/external/sqdproject dmlt equals multivariate fns and simbio are for forward models, it includes binaries iso2mesh is something Cristiano added, but it is unclear whether all of it is really needed, it includes binaries we don't need both spm2 and spm8. sqdproject is not needed any more. If I do rm -rf fieldtrip-lite-20120309/qsub rm -rf fieldtrip-lite-20120309/peer rm -rf fieldtrip-lite-20120309/engine rm -rf fieldtrip-lite-20120309/multivariate rm -rf fieldtrip-lite-20120309/realtime rm -rf fieldtrip-lite-20120309/external/dlmt rm -rf fieldtrip-lite-20120309/external/sqdproject rm -rf fieldtrip-lite-20120309/external/fns rm -rf fieldtrip-lite-20120309/external/simbio rm -rf fieldtrip-lite-20120309/external/iso2mesh rm -rf fieldtrip-lite-20120309/external/spm2 I end up with roboos@mentat001> du -hs fieldtrip-lite-20120309/ 58M fieldtrip-lite-20120309/ The resulting 58MB can be considered sufficiently "lite". I don't think that the trimmed down version affects a lot of functionality for novice users.

Robert Oostenveld - 2012-03-11 13:14:05 +0100

removing the suggested directories results in roboos@mentat001> ll -h daily/fieldtrip-* -rw-r--r-- 2 roboos coherence 125M Mar 11 13:11 daily/ -rw-r--r-- 2 roboos coherence 22M Mar 11 13:11 daily/ I consider that to be sufficiently "lite" and will do the release like this. The implementation uses the -x option with an exclude file that contains *.mat */qsub/* */test/* */peer/* */engine/* */multivariate/* */realtime/* */external/dmlt/* */external/sqdproject/* */external/fns/* */external/simbio/* */external/iso2mesh/* */external/spm2/* */external/yokogawa/*

Robert Oostenveld - 2012-04-11 16:48:38 +0200

I cleaned up my bugzilla list by changing the status from resolved (either fixed or wontfix) into closed. If you don't agree, please reopen the bug. Robert