<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Fabio Ticconi</title>
	<atom:link href="https://fabioticconi.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>https://fabioticconi.wordpress.com</link>
	<description></description>
	<lastBuildDate>Wed, 09 Mar 2016 12:31:22 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<site xmlns="com-wordpress:feed-additions:1">19111732</site><cloud domain='fabioticconi.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>https://s0.wp.com/i/webclip.png</url>
		<title>Fabio Ticconi</title>
		<link>https://fabioticconi.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="https://fabioticconi.wordpress.com/osd.xml" title="Fabio Ticconi" />
	<atom:link rel='hub' href='https://fabioticconi.wordpress.com/?pushpress=hub'/>
	<item>
		<title>Keep Your Linux SSH Session From Disconnecting</title>
		<link>https://fabioticconi.wordpress.com/2016/03/09/keep-your-linux-ssh-session-from-disconnecting/</link>
					<comments>https://fabioticconi.wordpress.com/2016/03/09/keep-your-linux-ssh-session-from-disconnecting/#respond</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Wed, 09 Mar 2016 12:31:22 +0000</pubDate>
				<category><![CDATA[Practical]]></category>
		<category><![CDATA[linux]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=557</guid>

					<description><![CDATA[via Keep Your Linux SSH Session From Disconnecting.]]></description>
										<content:encoded><![CDATA[<p>via <a href="http://www.howtogeek.com/howto/linux/keep-your-linux-ssh-session-from-disconnecting/">Keep Your Linux SSH Session From Disconnecting</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2016/03/09/keep-your-linux-ssh-session-from-disconnecting/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">557</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>How to compile Ncbi IgBlast with GCC &#062;= 5.X</title>
		<link>https://fabioticconi.wordpress.com/2016/01/08/how-to-compile-ncbi-igblast-with-gcc-5-x/</link>
					<comments>https://fabioticconi.wordpress.com/2016/01/08/how-to-compile-ncbi-igblast-with-gcc-5-x/#respond</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Fri, 08 Jan 2016 14:13:07 +0000</pubDate>
				<category><![CDATA[Practical]]></category>
		<category><![CDATA[bioinformatics]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=480</guid>

					<description><![CDATA[If you are trying compiling igblast from sources and get this error: configure: error: Do not know how to build MT-safe with compiler /usr/bin/g++  5.2.1 the fix is very simple. Open the file src/build-system/configure and search for this section: if test "$GCC" = "yes" ; then compiler_ver="`$real_CXX -dumpversion 2&#62;&#38;1`" case "$compiler_ver" in 2.95* &#124; 2.96* [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>If you are trying compiling igblast from sources and get this error:</p>
<blockquote><p>configure: error: Do not know how to build MT-safe with compiler /usr/bin/g++  5.2.1</p></blockquote>
<p>the fix is very simple. Open the file <strong>src/build-system/configure</strong> and search for this section:</p>
<blockquote>
<pre><code>if test "$GCC" = "yes" ; then
   compiler_ver="`$real_CXX -dumpversion 2&gt;&amp;1`"
   case "$compiler_ver" in
     2.95* | 2.96* | 3.* | 4.* )
       compiler="GCC"
       ncbi_compiler="GCC"
       ncbi_compiler_ver="$compiler_ver"
                 WithFeatures="$WithFeatures${WithFeaturesSep}GCC"; WithFeaturesSep=" "
       ;;
   esac
</code></pre>
</blockquote>
<p>What it does is it checks that GCC has one of the specified versions, including any version 3 or version 4. No version 5, sadly.. so just change the following line:</p>
<blockquote><p><code>2.95* | 2.96* | 3.* | 4.* )</code></p></blockquote>
<p>with</p>
<blockquote><p><code>2.95* | 2.96* | 3.* | 4.* <strong>| 5.*</strong> )</code></p></blockquote>
<p>Now save and go back to the release/ directory, and run the usual <strong>./configure &amp;&amp; make &amp;&amp; sudo make install</strong> command.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2016/01/08/how-to-compile-ncbi-igblast-with-gcc-5-x/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">480</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>Short C++ remainder on passing objects to functions</title>
		<link>https://fabioticconi.wordpress.com/2015/05/09/short-c-remainder-on-passing-objects-to-functions/</link>
					<comments>https://fabioticconi.wordpress.com/2015/05/09/short-c-remainder-on-passing-objects-to-functions/#comments</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Sat, 09 May 2015 17:25:33 +0000</pubDate>
				<category><![CDATA[Practical]]></category>
		<category><![CDATA[c++]]></category>
		<category><![CDATA[programming]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=458</guid>

					<description><![CDATA[Suppose you have an Object class. You instantiate three objects locally: Object o1, o2, o3; Then you have a function: void f(Object o1, Object &#38;o2, Object * o3); This summarises the three ways you can pass an object to a function: by value, by reference and by reference via a pointer (let&#8217;s call it for [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>Suppose you have an <strong>Object</strong> class. You instantiate three objects locally:</p>
<p><code>Object o1, o2, o3;</code></p>
<p>Then you have a function:</p>
<p><code>void f(Object o1, Object &amp;o2, Object * o3);</code></p>
<p>This summarises the three ways you can pass an object to a function: <strong>by value, by reference and by reference via a pointer </strong>(let&#8217;s call it for simplicity <strong>call by pointer</strong>). Say you call the function like this:</p>
<p><code>f(o1, o2, &amp;o3);</code></p>
<p>Inside the function, you may access these objects&#8217; fields like this (note <em>o3</em>):</p>
<p><code>o1.x  += 3;<br />
o2.x  += 3;<br />
o3-&gt;x += 3;</code></p>
<hr />
<p>These are the take home messages:</p>
<ul>
<li><strong>[Call by value]:</strong><em> o1</em> is going to be <strong>copied</strong> inside the function <em>f</em>, then after <em>f</em> returns the copy is going to be destroyed. This means that <strong>any changes made by <em>f </em>onto <em>o1</em> are not going to be visible outside <em>f</em>. </strong>In addition to being unsuitable to persist changes, the copy overhead can be very deleterius in certain high-performance applications &#8211; however, there is no access overhead.</li>
<li><strong>[Call by reference]:</strong><em> o2</em> is NOT going to be copied, so <strong>any changes made to <em>o2</em> inside <em>f</em> are going to remain even after <em>f</em> returns</strong>. This is very efficient: no copy and methods/fields have no access overhead.</li>
<li><b>[Call by pointer]: </b>you are actually passing a pointer to <em>o3</em> to <em>f</em>, so to access the objects&#8217; fields and methods you need to dereferentiate every time (using the <strong>-&gt;</strong> operator). This makes it averagely efficient: no copy but access overhead.</li>
</ul>
<p>It&#8217;s clear that, even when you don&#8217;t actually need to modify an object, <strong>call by reference should be your default approach.</strong></p>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2015/05/09/short-c-remainder-on-passing-objects-to-functions/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">458</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>KryoNet: very fast and easy to use network library</title>
		<link>https://fabioticconi.wordpress.com/2014/08/24/kryonet-very-fast-and-easy-to-use-network-library/</link>
					<comments>https://fabioticconi.wordpress.com/2014/08/24/kryonet-very-fast-and-easy-to-use-network-library/#respond</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Sun, 24 Aug 2014 19:39:27 +0000</pubDate>
				<category><![CDATA[Practical]]></category>
		<category><![CDATA[game development]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[MUD]]></category>
		<category><![CDATA[networking]]></category>
		<category><![CDATA[programming]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/2014/08/24/kryonet-very-fast-and-easy-to-use-network-library/</guid>

					<description><![CDATA[I&#8217;ve been experimenting a bit with this library and it&#8217;s a relief: I don&#8217;t have to maintain my own (crappy) one within ZenithMUD. Easy to use, documented and very efficient, according to benchmarks I&#8217;ve found around. One can use the start() method that runs the library in a Thread and takes care of getting data from the [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>I&#8217;ve been experimenting a bit with this library and it&#8217;s a relief: I don&#8217;t have to maintain my own (crappy) one within ZenithMUD.</p>
<p>Easy to use, <a href="https://github.com/EsotericSoftware/kryonet">documented</a> and very efficient, according to benchmarks I&#8217;ve found around. One can use the <strong>start()</strong> method that runs the library in a Thread and takes care of getting data from the connected clients and running user-defined actions on them, or just call the <strong>update()</strong> function in your own game loop (if you are more of a control freak :))</p>
<p>A good starting point, besides the README, is this <a href="https://github.com/EsotericSoftware/kryonet/tree/master/examples/com/esotericsoftware/kryonet/examples/chat">Chat client-server example the author has provided.</a></p>
<p>Good job!</p>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2014/08/24/kryonet-very-fast-and-easy-to-use-network-library/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">426</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>Things every wanna-be game designer/developer should know</title>
		<link>https://fabioticconi.wordpress.com/2014/02/08/things-every-wanna-be-game-designerdeveloper-should-know/</link>
					<comments>https://fabioticconi.wordpress.com/2014/02/08/things-every-wanna-be-game-designerdeveloper-should-know/#respond</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Sat, 08 Feb 2014 19:54:10 +0000</pubDate>
				<category><![CDATA[Thoughts]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=409</guid>

					<description><![CDATA[Game Design 101 by Tom Sloper Very funny and thoughtful series of advice, divided in more than 80 &#8220;lessons&#8221;, on the common pitfalls of young chaps with a strong will to make their own game.. or so they think. &#8216;Cause the will, the determination, easily withers when faced with the reality of making a proper game. [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a href="http://sloperama.com/advice/idea.htm">Game Design 101 by Tom Sloper</a></p>
<p>Very funny and thoughtful series of advice, divided in more than 80 &#8220;lessons&#8221;, on the common pitfalls of young chaps with a strong will to make their own game.. or so they think.</p>
<p>&#8216;Cause the will, the determination, easily withers when faced with the <strong>reality</strong> of making a proper game. Read carefully!</p>
<p>An excerpt on why you won&#8217;t get other people (programmers, artists or whatever) do most of the work for you just because you had the Fantastic Idea:</p>
<blockquote><p>Pretend for a moment that you have a great idea for a novel, not a game. How would you go about getting it written and published? Would you go to a bulletin board and advertise looking for an author to write it for you? No, you would have to get off your butt and write it yourself. I have heard that a friend of Frank Herbert (author of Dune) asked Herbert to author the friend&#8217;s idea and split the profits 50/50. Herbert refused, even though the guy was a good friend &#8212; Herbert&#8217;s reply was basically that ideas are easy; the writing is the hard part. Think about it for a minute &#8212; would YOU want to have a friend come up to you, tell you a few sentences, then have you spend months hunched over a keyboard turning his few sentences into the Great American Novel? I doubt it. If you <i>did</i> spend months writing that book, would you want to give half of the money to that guy? I don&#8217;t think so.</p></blockquote>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2014/02/08/things-every-wanna-be-game-designerdeveloper-should-know/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">409</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>If only humans were as good-natured as animals..</title>
		<link>https://fabioticconi.wordpress.com/2012/06/19/if-only-humans-were-as-good-natured-as-animals/</link>
					<comments>https://fabioticconi.wordpress.com/2012/06/19/if-only-humans-were-as-good-natured-as-animals/#comments</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Tue, 19 Jun 2012 11:25:40 +0000</pubDate>
				<category><![CDATA[Thoughts]]></category>
		<category><![CDATA[animal behaviour]]></category>
		<category><![CDATA[animals]]></category>
		<category><![CDATA[biology]]></category>
		<category><![CDATA[ethics]]></category>
		<category><![CDATA[humans]]></category>
		<category><![CDATA[nature]]></category>
		<category><![CDATA[science]]></category>
		<category><![CDATA[society]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=255</guid>

					<description><![CDATA[..what a wonderful world would it be! we would often be commiting infanticide for the sake of our lineage we would be defining strict hierarchies where only two individuals are allowed to reproduce, or where the male has a harem of several females and fights hard any competitors we would have males poisoning their female &#8220;soul mate&#8221;, [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>..what a wonderful world would it be!</p>
<ul>
<li>we would often be<a href="http://www.sciencedirect.com/science/article/pii/0162309579900049"> commiting infanticide</a> for the sake of our lineage</li>
<li>we would be defining strict hierarchies where only two individuals are allowed to reproduce, or where the male has a <em>harem</em> of several females and fights hard any competitors</li>
<li>we would have males poisoning their female &#8220;soul mate&#8221;, but since she&#8217;d do the same with a stronger poison these males would inevitably die</li>
<li>we would have males beating their females and going with little armies to kill nearby <a href="http://www.nytimes.com/2010/06/22/science/22chimp.html">groups of the same species</a> or of other species, <a href="http://www.nsf.gov/news/special_reports/science_nation/bonobos.jsp">you know, the one that only thinks about sex</a></li>
<li><a href="http://en.wikipedia.org/wiki/Animal_suicide">we would be committing suicide</a>, either alone or &#8220;kamikaze style&#8221;</li>
</ul>
<p>and plenty of other funny and lovely things!</p>
<h2>On a more serious note</h2>
<p>I know the common objection to this. &#8220;They cannot choose&#8221;, &#8220;It&#8217;s their nature&#8221; and so on. What really does bug me is that people aren&#8217;t able to see that we <strong>humans are actually an improvement</strong>, because we <em>can</em> choose and we <em>can</em> define our own &#8220;nature&#8221;, which becomes culture- and ratio-based instead of strictly genetic/impulsive.</p>
<p>Ethics can be defined, followed, enforced by law. All the bad things I listed, that indeed have been proudly performed by many humans and still cause suffering to a lot of people in the world, can be made forbidden or depicted as despicable, thus reducing them statistically.</p>
<p>In some of the cited articles, you may read explanations of <strong>why animals do such bad things.</strong> Sometimes had been indeed proved that those behaviours increase their probability, as a species, to survive.</p>
<p><strong>I don&#8217;t know if you noticed, but the important thing seems to be the &#8220;species&#8221; when talking about animals. Not the &#8220;individual&#8221;.<br />
</strong></p>
<p>Would you really like that? We have been constructing abstract wrappings around pain and suffering (as well as good feelings) for thousands of years, but you know: also animals suffers. When a male lion kills a pup, his mother (maybe, I don&#8217;t know) suffers <a href="http://www.acclaimimages.com/search_terms/animal_infanticide.html">but the pup suffers more, before dying</a>. It&#8217;s physical suffering, which is really bad.</p>
<p><strong>I guess it&#8217;s also worse when they starve to death or are plagued by different kind of damn diseases.</strong></p>
<p>Would you like that to happen to you, your family, your friends? Don&#8217;t you see how humans, yet despicable on many areas, <strong>are actually an improvement for the individual, regardless of the species?</strong></p>
<p>For me the individual is important, what I feel, what I want, and the same for the people near me: the more &#8220;far away&#8221; they are, the less I care. And that&#8217;s pretty normal: we&#8217;d die in a minute if we cared about <em>all</em> problems affecting people worldwide.</p>
<p>A lot still has to be done, on the ethical and technological side, to build a really safe and enjoyable world for us and our beloved.</p>
<p>For sure, the wrong way is that of be willing to go back to tribal societies, reviving our animal instincts, because animals are soooo cute and they are full of love while we are just reckless filthy humans.</p>
<h2>Go down from the trees, ethical-driven humans! Your modern society needs you. Well educated, conscious and rational.</h2>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2012/06/19/if-only-humans-were-as-good-natured-as-animals/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">255</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>How to remotely use your workstation with ssh and vnc</title>
		<link>https://fabioticconi.wordpress.com/2011/01/20/how-to-remotely-use-your-workstation/</link>
					<comments>https://fabioticconi.wordpress.com/2011/01/20/how-to-remotely-use-your-workstation/#respond</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Thu, 20 Jan 2011 20:30:29 +0000</pubDate>
				<category><![CDATA[Practical]]></category>
		<category><![CDATA[computer]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[operative system]]></category>
		<category><![CDATA[remote control]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[vnc]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=56</guid>

					<description><![CDATA[I assume that you use a Unix-like operative system, but this apply to any OS. Let&#8217;s say about a problem: you are in your office, you are waiting for some kind of simulation to end. Everything seems to go well, so you go home, quite confident that the next morning you&#8217;ll have some results to [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><em>I assume that you use a <a class="zem_slink" title="Unix-like" rel="wikipedia" href="http://en.wikipedia.org/wiki/Unix-like">Unix-like</a> operative system, but this apply to any OS.</em></p>
<p>Let&#8217;s say about a problem: you are in your office, <strong>you are waiting for some kind of simulation to end</strong>. Everything seems to go well, so you go home, quite confident that the next morning you&#8217;ll have some results to analyze.</p>
<p><a href="http://en.wikipedia.org/wiki/Murphy%27s_law">Unfortunately</a>, it&#8217;s unlikely to happen. Ten seconds after your departure, <strong>the program ends</strong> for a low-frequency bug that you missed.</p>
<p>Luckily, we have a solution for the future. Instead of losing a long night (or even a weekend) of program executions, <strong>you can check your office workstation</strong> when you are at home, in your warm bed, or everywhere you like to be (with an internet connection, <em>ça va sans dire</em>).</p>
<h2>What do you need in your workstation?</h2>
<p>You need to install (or ask the sysadmin to install):</p>
<ol>
<li>the <strong>ssh server</strong></li>
<li>a vnc server: <strong>x11vnc</strong></li>
</ol>
<p>Remember to ask the sysadmin:</p>
<ol>
<li>the public IP of your workstation</li>
<li>the range of unused open ports, if the workstation is behind a router</li>
</ol>
<h2>What do you have to do from home?</h2>
<p>Ok, now it&#8217;s very simple. You&#8217;ll only need to install a <strong>vncviewer</strong>, but you&#8217;ll probably already have one. Let&#8217;s say that your workstation username is <strong>goofy</strong>, the public IP is <strong>1.0.0.1</strong>, and the free open port on the workstation is the <strong>5900</strong>. Now we need another port, this time a local one (of your home computer), to create the http tunnel. I suggest the port 5901:</p>
<p><code>ssh -p 42 -L 5901:localhost:5900 goofy@1.0.0.1</code></p>
<p>You&#8217;ll have to insert your workstation password, and then you can explore with the shell your remote operative system. If you want to use it graphically, only execute the command:</p>
<p><code>x11vnc</code></p>
<p>Wait for 5-6 seconds, then open another shell <strong>without closing the current one</strong>, and type the following:</p>
<p><code>vncviewer localhost::5901</code></p>
<p><em>Et voilà!</em> You have to move your mouse on the new black window, and then you&#8217;ll see the remote display to appear.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2011/01/20/how-to-remotely-use-your-workstation/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">56</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>
	</item>
		<item>
		<title>How to do a word alignment with GIZA++ or MGIZA++ from parallel corpus</title>
		<link>https://fabioticconi.wordpress.com/2011/01/17/how-to-do-a-word-alignment-with-giza-or-mgiza-from-parallel-corpus/</link>
					<comments>https://fabioticconi.wordpress.com/2011/01/17/how-to-do-a-word-alignment-with-giza-or-mgiza-from-parallel-corpus/#comments</comments>
		
		<dc:creator><![CDATA[Fabio T.]]></dc:creator>
		<pubDate>Mon, 17 Jan 2011 20:24:19 +0000</pubDate>
				<category><![CDATA[Practical]]></category>
		<category><![CDATA[computational linguistics]]></category>
		<category><![CDATA[computer science]]></category>
		<category><![CDATA[corpus linguistics]]></category>
		<category><![CDATA[europarl]]></category>
		<category><![CDATA[giza]]></category>
		<category><![CDATA[machine learning]]></category>
		<category><![CDATA[machine translation]]></category>
		<category><![CDATA[mgiza]]></category>
		<category><![CDATA[parallel corpus]]></category>
		<category><![CDATA[statistical machine translation]]></category>
		<category><![CDATA[word alignment]]></category>
		<guid isPermaLink="false">http://fabioticconi.wordpress.com/?p=81</guid>

					<description><![CDATA[I assume that you are working with a *nix box, and that you use a bash-like shell. You need the sentence aligned europarl corpora for each language you like to train the word alignment. Please check that the corpora have the same number of lines and that they are correctly aligned. If you don&#8217;t want [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><em>I assume that you are working with a *nix box, and that you use a bash-like shell.</em></p>
<p>You need the sentence aligned <a href="http://www.statmt.org/europarl/">europarl corpora</a> for each language you like to train the word alignment. Please check that the corpora have the same number of lines and that they are correctly aligned.</p>
<p>If you don&#8217;t want to do it, you can use <a href="http://dl.dropbox.com/u/23664530/europarl_corpora_sent_align.tar.gz">the sentence aligned europarl corpora</a> built by <strong>Els Lefever</strong>. They are raw (no xml tags, but capital letter and words not well separated), so if you want the word alignment you have to follow all of next steps. Note that they are compressed in a tar.gz archive, and that are only six languages: english, italian, french, spanish, german and dutch. If you want to use different languages but you don&#8217;t know how to do, please comment this post.</p>
<h2>First of all</h2>
<p>You want to do a word alignment between two languages. We call the two languages the <strong>source language</strong> and the <strong>target language</strong>. This is important in order to correctly do the word alignment, so decide which language will be the source and which the target.</p>
<p>I can help you saying that the word alignment is only one-to-one, NULL-to-one and many-to-one. So if you choose english as source language and french as target, you can have an alignment like this:</p>
<div class="zemanta-img">
<div style="width: 310px" class="wp-caption aligncenter"><a href="http://commons.wikipedia.org/wiki/File:Word_alignment.svg"><img class="zemanta-img-configured" title="Word alignment example" src="https://i0.wp.com/upload.wikimedia.org/wikipedia/commons/thumb/7/7a/Word_alignment.svg/300px-Word_alignment.svg.png" alt="Word alignment example" width="300" height="115" /></a><p class="wp-caption-text">Image via Wikipedia</p></div>
<p>You may want to make a function like this:</p>
<p><img src="https://s0.wp.com/latex.php?latex=f%28english%29+%3D+french+&#038;bg=ffffff&#038;fg=333333&#038;s=0&#038;c=20201002" srcset="https://s0.wp.com/latex.php?latex=f%28english%29+%3D+french+&#038;bg=ffffff&#038;fg=333333&#038;s=0&#038;c=20201002 1x, https://s0.wp.com/latex.php?latex=f%28english%29+%3D+french+&#038;bg=ffffff&#038;fg=333333&#038;s=0&#038;c=20201002&#038;zoom=4.5 4x" alt="f(english) = french " class="latex" /></p>
<p>that is impossible with the alignment before. In this case you have to use the french as source language, and english as target.</p>
<p>In the next sections, I&#8217;ll use for each file name this convention: <strong>source = .src and target = .trg</strong></p>
<p>So for example, if you downloaded my raw corpora and <strong>you want to do an english (source) to french (target) alignment</strong> (like in the image above), you can think raw_corpus.src as raw_corpus.en and raw_corpus.trg as raw_corpus.fr.</p>
<h2>Pre-processing</h2>
<p>We have to clean up the corpora, set every word in lower case and separate every word from each other (or we can say &#8220;tokenizing&#8221;). We need the tools of the europarl maintainers, you can download it here:</p>
<p><a href="http://www.statmt.org/europarl/v5/tools.tgz">http://www.statmt.org/europarl/v5/tools.tgz</a></p>
<p>Now enter the subdirectory <strong>tools</strong>, and take the script <strong>tokenizer.perl</strong> and the directory <strong>nonbreaking_prefix</strong> (they should be in the same directory!).</p>
<p>The nonbreaking_prefix let the tokenizer keep together words like &#8220;Mr.&#8221;. Normally the tokenizer would have broken it into two words: &#8220;Mr&#8221; and &#8220;.&#8221;, but we know that the final dot is useful, not a real punctuation.</p>
<p>Into tools.tgz there aren&#8217;t prefixes for every language, so <a href="http://dl.dropbox.com/u/23664530/nonbreaking_prefixes.zip">I did my own</a>. You can freely use it, and if you correct it please contact me.</p>
<p>Now, let&#8217;s tokenize!</p>
<p><code>tokenizer.perl -l src &lt; raw_corp.src &gt; corp.tok.src<br />
tokenizer.perl -l trg &lt; raw_corp.trg &gt; corp.tok.trg</code></p>
<p>And now you can lowercase every word:</p>
<p><code>tr '[:upper:]' '[:lower:]' &lt; corp.tok.src &gt; corp.tok.low.src<br />
tr '[:upper:]' '[:lower:]' &lt; corp.tok.trg &gt; corp.tok.low.trg</code></p>
<h2>Making class and cooccurrence</h2>
<p>Now you have to choose: <a href="http://geek.kyloo.net/software/doku.php/mgiza:overview">MGIZA</a> or <a href="http://code.google.com/p/giza-pp/">GIZA</a>?</p>
<p>They are equals, but MGIZA is multi-threaded, GIZA not. My advice is to choose MGIZA, but if you have to align lot of languages you can execute multiple times GIZA for each language, so it&#8217;s your choice. I&#8217;ll write explicitly when an option if for MGIZA only.</p>
<p>After you have downloaded, built and installed your favourite tool, we can go forward.</p>
<p>Making classes (necessary for algorithm HMM):</p>
<p><code>mkcls -n10 -pcorp.tok.low.src -Vcorp.tok.low.src.vcb.classes<br />
mkcls -n10 -pcorp.tok.low.trg -Vcorp.tok.low.trg.vcb.classes</code></p>
<p>Translate the corpora into GIZA format:</p>
<p><code>plain2snt corp.tok.low.src corp.tok.low.trg</code></p>
<p>Create the cooccurence:</p>
<p><code>snt2cooc corp.tok.low.src_corp.tok.low.trg.cooc corp.tok.low.src.vcb corp.tok.low.trg.vcb corp.tok.low.src_corp.tok.low.trg.snt</code></p>
<h2>Finally aligning!</h2>
<p>You only need, now, a configuration file for MGIZA or GIZA. <strong>I use <a href="http://pastebin.com/b1ksHtUy">this</a></strong>, you only have to change &#8220;.src&#8221; and &#8220;.trg&#8221; with the correct language strings: &#8220;it&#8221;, &#8220;en&#8221;, &#8220;fr&#8221;, etc.</p>
<p>If you use GIZA, you have to delete the line &#8220;ncpus&#8221; from this config file. Otherwise, with MGIZA, set it to the number of cpu/core that you have. Remember that if you have a cpu with hyperthreading, you can multiply the number of core by two (I&#8217;ve an Intel i740 quad-core, so I&#8217;ve &#8220;ncpus 8&#8221;).</p>
<p>Cross your fingers and type:</p>
<p><code>mgiza configfile</code></p>
<p>After many hours, you&#8217;ll get as many output files as &#8220;ncpus&#8221;, in this format:</p>
<p><code>src_trg.dict.A3.final.part0<br />
src_trg.dict.A3.final.part1<br />
src_trg.dict.A3.final.part2<br />
...</code></p>
<p>You only have to concatenate them, and you have your word alignment!</p>
<h2>Little script for lazy ones</h2>
<p><a href="http://pastebin.com/ipEzdUvP">I did a simple script</a> that does the things I said before, you only need to adapt it to your languages. Now it makes five word alignments, from &#8220;italian/dutch/french/german/spanish&#8221; languages to &#8220;english&#8221;. You can freely use it if you want.</p>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://fabioticconi.wordpress.com/2011/01/17/how-to-do-a-word-alignment-with-giza-or-mgiza-from-parallel-corpus/feed/</wfw:commentRss>
			<slash:comments>45</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">81</post-id>
		<media:content url="https://1.gravatar.com/avatar/a363a3c9297cc5af541b9c633dab007110f6299552b307e0c3e2f68dab18c9d4?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">koteko</media:title>
		</media:content>

		<media:content url="http://upload.wikimedia.org/wikipedia/commons/thumb/7/7a/Word_alignment.svg/300px-Word_alignment.svg.png" medium="image">
			<media:title type="html">Word alignment example</media:title>
		</media:content>
	</item>
	</channel>
</rss>
