MonthJanuary 2011

Curfew ciao

Technically there is a curfew issued at the moment in egypt.

This, however is the idea of the Egyptian people.

Curfew not respected Egypt

Curfew not respected Egypt

They took down the internet, they’ve called the army, they made the police to shout, however they didn’t stop them and their are becoming more and more.
Live English stream from Al Jazeera here
Go Egypt Go!

Being a little gear

Sul fattoquotidiano c’è un canale seguito da Andrea Valdambrini sui cervelli in fuga, dove si raccontano le storie di esuli italiani fuggiti dall’Italia, molte volte non per scelta, ma per necessità.

Molti di questi sono scienziati, la cui capacità non vengono valutate secondo criteri meritocratici, ma secondo criteri di conoscenze e parentele. Ok, same old story fino a qui.
L’unica cosa interessante è che di queste cose bisogna parlarne e siccome è appena uscito un articolo che proviene da Cambridge, dove momentaneamente risiedo, e visto che il contatto tra Chiara ed Andrea sono stato io, pensavo che era interessante linkarlo.

Lo trovate qui.

Come ha scritto un commentatore sul fatto, questa non è una storia isolata, ma un’atteggiamento sistematico del sistema Italico verso persone brave e competenti, che vengono scartate a favore di qualcuno che invece non è capace di fare quel lavoro. O a favore di un depauperamento della ricerca, chiudendo i finanziamenti alla ricerca di base che è appunto di base, e senza la quale la famosa applicata non esisterebbe.

Neuronvisio 0.5.2 released

There is a new release of Neuronvisio out there, version 0.5.2. Given the fact that our userbase is growing, I have tried to repackage it properly to make it easy to install, and to build the doc on the site.

It should be installable using pip (at least it works on my tests)..

Of course the code is always on github repo.

Reviewing Paperpile 0.5 beta

paperpile logo

Paperpile is a nice software which hit the 0.5 beta version some days ago. It’s been a while that I’m using it and being in the full swing of writing my Thesis, I tend to use it on daily basis, so I decided to review it a bit.

First of all Paperpile is a reference manager, which help to manage, organize, cite and share the collection of scientific papers that you have on your computer. If you do science you know exactly what I’m talking about. If you don’t, imagine you have at least 200 different articles lying on your hard drive, which analyse different but related subjects. When writing a new research article, it’s necessary to cite all the relevant previous work to put you new work in contest. It’s the incremental delta of new information which science uses to evolve (when there is not a quantum leap).

Retrieving, organizing and citing those piece of work is necessary and can be a daunting task, but a good reference manager can help to make your life easier. There are several softwares out there, and I had different experiences, however it seems Paperpile is overcoming anything else and I’m using it productively, making me even to read more papers!

So let’s jump into it.

Paperpile general

General view of Paperpile

This is the general window of paperpile. On the Top left you can see the label à la gmail. More than one label can be added to a paper and different background/foreground colour can be used to personalize it. To add an existing label to a paper just pick and drag it over it. Super easy.

On the Mid right you can add the RSS from journals, which can help you to be updated with the latest articles published. I used to have this RSS in my google reader, however having it directly in paperpile makes super easy to import new papers and collect the pdf.

Bottom right there is a collection of different tool, from being able to search Pubmed to import a directory full of PDF.

Central window is where the meat is. All the paper, ordered by addiction Date (you can change to what you prefer) and the most important feature: the search box. Paperpile implements a search as you type system, so as soon you start to type it it start to search in author title and also abstract.

One very interesting bit is that the search box actually find the article I’m usually looking for, and it’s pretty precise. It really saves me a lot of time. This is a clear edge over Mendeley for example, where the search was a disaster. At least in the version I’ve used so far.

The central window also give you the possibility to add notes to a paper.

On top left there are very useful actions which paperpile can perform for you. Paperpile makes easy to retrieve the article on to the publisher site, either giving you a link to visit the webpage or can automatically fetch the paper for you. Sweet!

Another very useful features, which I used so far at least 3 times, is the automatically generated email, which fire up an already ready to send email to your colleagues with the citation reference.

One last thing that I would like to put under the light is the LaTeX integration. With an easy Ctrl-K the label will be copied in your clipboard ready to be pasted in your LaTeX file. If you need the more standard citation, Ctrl-C will do.

To set up the automatically synch for your bibtex database just click on All Papers, on the top-left and turn it on, choosing the location for the file. After that every new paper you’ll add to your collection is automatically exported in BibTeX and you don’t have to care about it at all 🙂

Paperpile BiBTeX setting

Go and Check it out.

I would like to speak with Salvatore

On the guardian there is an article about about Berlusconi, where also Rocco Siffredi is questioned about the RubyGate and the possible effect on the number of votes.

If I get the article correctly it seems that Rocco is saying that Berlusconi will not loose vote for this behaviour. I’m always amazed when people can predict how and what people will behave in an election that is not yet issued, basing their judgement on one fact.

More over, in a youtube video, I remember that Rocco said that Berlusconi is ill and that he can help him. So I don’t know if he changed his opinion or the article is a bit imprecise.

However the number of voters for Berlusconi is a straw argoment.

Berlusconi has a pack of voters whom will vote for him no matter what. This is more like a cult problem than an actually political judgement of what the govern has achieved. This people exist and it will be stupid not to acknowledge that, however this is a fraction of all the voters in Italy.

A third of the country didn’t vote at the last elections. They didn’t vote neither for the right wing or for the left wing. Lack of proper representation it seems to be more the cause of this then not being interested in the politic of the country. What I would like to make clear is that there is a huge pool of possible voters, which could be called to get rid of Berlusconi.

But this is not what I wanted to write about. I would like to comment this sentence:

Salvatore, a blacksmith, said: “I would give my daughter a slap if she went to a party at Berlusconi’s, but I still vote for him since I approve of his politics.”

I really would like to understand what is this politics that he his talking about. The Berlusconi’s politics, in the last 14 years, was only escaping from the law using the power to create new law that will favour him (ad personam), or to change existing law. That’s not politics, that’s tilting the table.

So the number of people that actually vote for Berlusconi are either thinking he is a model or they are convinced he is doing good the job. The last part are completely recoverable because it will be easy to demonstrate that the government is unable to do its own job and its completely stopped.

There is a massive amount of people that could throw away Berlusconi. The only trouble is that the left wing did not yet find the way to organize those people in a coherent way and be able to challenge him.

Several different way are being tried, like http://www.prossimaitalia.it/. We will see.

Sulle dimissioni di Berlusconi

Le dimissioni di Berlusconi sono oramai un atto dovuto per reclamare quella differenza culturale che è presente in Italia e che deve ritornare main stream.

Sul post questo viene analizzato in maniera impeccabile.

Appeal for Berlusconi’s Resignation

1. Resignation.
We call upon Silvio Berlusconi to resign immediately from his post as Presidente del Consiglio dei Ministri. In no other democratic country would a Prime Minister, faced with such serious legal accusations, remain in office longer than a few hours. All Italian citizens, of whatever political persuasion, must realise that the image of their country is profoundly tainted if Berlusconi remains in office.
2. Attendance in court.
We call upon Silvio Berlusconi not to defend himself on television, using his substantial mediatic power to discredit the magistrates, but to present himself in court and seek to defend himself there, as would any normal citizen. Once in court, he can in any case hope to benefit from the services of the highest paid lawyers in the country. We sincerely hope, for his sake and that of the country, that he is able to demonstrate his innocence. If he and his supporters reply that the judges are irremediably biased against him, we would like to point out that on more than one occasion in the past he has been given the benefit of the doubt by the courts. In the Mondadori case, for example, the court judged in 2001 his position as Head of Government to be part of the ‘extenuating circumstances’ which in his case alone allowed the crime to be prescribed.
3. The role of the President of the Republic
In a situation in which two of the principal powers of the state – the magistracy and the executive – are on a head-on collision course of considerable danger for the future of the Republic, we call upon its President to observe closely the situation and to be prepared to intervene actively, naturally within the limits of the powers ascribed to his office by the Constitution.
4. The opposition parties
We call upon all the parties of the opposition to put aside their differences and to abandon any jockeying for position, uniting instead their voices in a single request of a single word: RESIGNATION.
5. Civil Society
We invite the many associations and the hundreds of thousands of members of civil society to do the same, pooling their resources and joining hands on a single line of action. We would particularly appeal to Catholic civil society to deplore the hesitations and silences of the Vatican on so important an issue of public ethics.
6. The friends of Italy in the world
We have written this appeal in English as well as Italian in order to reach all those abroad who are friends of Italian democracy. Do not despair of Italy! The country needs your solidarity and help.

Gustavo Zagrebelsky, Paul Ginsborg e Sandra Bonsanti per tutta Libertà e Giustizia

I completely agree and I repost it here. Original on the “Libertà e Giustizia” website.

Retroffiting with style:the cinquino elettrico

Pietro Cambi is the president of the Eurozev, an association which promotes the conversion from endothermic engine to electric. He converted his own ‘cinquino’ to an electric car, manteining a lot of the original specs (like for example the clutch!)

cinquino picture

Cinquino and the kitegen prototype in the back. At the right side of cinquino Pietro Cambi, at the left side Massimo Ippolito, the kitegen's inventor

 

There is a video on youtube when the cinquino hit the 100 Km/h (the endothermic cinquino was never that fast 🙂

This is pretty cool and I think the way to go.

Sei stato nominato

Allora sembra che il nuovo nome del partito di B. si chiami Italia. Si avete letto bene. Almeno secondo quelli dell’agenzia dire.

Ora, oltre al fatto che già con Forza Italia era stato rubata la possibilità di tifare la nazionale (specialmente quella del rugby), ed ogni volta che vedo una partita la cosa mi imbestialisce un pò, adesso addirittura il nome del paese è il nome di un partito politico.

Si sospetta che il nome sia stato scelto utilizzando il generatore casuale di metilparaben

Questo era una delle possibilità e non ho capito perchè sia stata scartata…

Profiling python app

If you have to profile application, in python for example, it’s good to read this blog post which I found very useful information.

The profile is used to compare pytables, a python imlementation of HDF5 and pickle, which is a classic choice which you ran into if you are dealing with saving big files on the harddrive.

The best tool so far seems to be the massif profiler, which comes with the valgrind suite. How valgrind works:

This will run the script through valgrind

valgrind --tool=massif python test_scal.py

This produces a “massif.out.?????” file which is a text file, but not in a very readable format. To get a more human-readable file, use ms_print

ms_print massif.out.????? > profile.txt

So I’ve run some test to check the scalability of HDF5.

[sourcecode language=”python”]
import tables
import numpy as np

h5file = tables.openFile(‘test4.h5′, mode=’w’, title="Test Array")
array_len = 10000000
arrays = np.arange(1)

for x in arrays:
x_a = np.zeros(array_len, dtype=float)
h5file.createArray(h5file.root, "test" + str(x), x_a)

h5file.close()
[/sourcecode]

This is the memory used for one array

 

profile_one_array

Profiling one numpy array

This is for two arrays

profile_two_arrays

Profiling two numpy arrays

Four arrays

profiling_four_arrays

Profiling four numpy arrays

And this is for fifty

profile_fifty_arrays

Profiling fifty numpy arrays

As soon you enter the loop the efficiency is preserved in a really nice way
Summing up:

  • one ~ 87 Mb
  • two ~ 163 Mb
  • four ~ 163 Mb
  • fifty ~ 163 Mb

So the problem is not on pytables, but it lies somewhere else..

© 2017 Train of Thoughts

Theme by Anders NorénUp ↑

By continuing to use the site (scrolling or clicking counts), you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close