Friday, December 09, 2011

Semantic Web

"...Instead of asking machines to understand people’s language, it involves asking people to make the extra effort...." T. Berners-Lee, 1998, about the concept of machine-understandable documents.
Soure: A Semantic Web is not Artificial Intelligence

Thursday, December 01, 2011

Easier to ask for forgiveness than permission - Programming

EAFP
Easier to ask for forgiveness than permission. This common Python coding style assumes the existence of valid keys or attributes and catches exceptions if the assumption proves false. This clean and fast style is characterized by the presence of many try and except statements. The technique contrasts with the LBYL style common to many other languages such as C.
LBYL
Look before you leap. This coding style explicitly tests for pre-conditions before making calls or lookups. This style contrasts with the EAFP approach and is characterized by the presence of many if statements. In a multi-threaded environment, the LBYL approach can risk introducing a race condition between “the looking” and “the leaping”. For example, the code, if key in mapping: return mapping[key] can fail if another thread removes key from mapping after the test, but before the lookup. This issue can be solved with locks or by using the EAFP approach.

Strong vs weak typing in programming

Example


Weak Typing Strong Typing
Pseudocode
a = 2
b = "2"
 
concatenate(a, b) # Returns "22"
add(a, b)         # Returns 4
a = 2
b = "2"
 
concatenate(a, b)     # Type Error
add(a, b)             # Type Error
concatenate(str(a), b) # Returns "22"
add(a, int(b))         # Returns 4
Languages Perl, PHP, Rexx, JavaScript, BASIC Java, C, C++, Python, C#, Vala

Friday, November 18, 2011

Suppression du modèle {{spoiler}} dans wikipedia

Intéressant débat multi-lingue sur la suppression du modèle {{spoiler}} dans wikipedia:
J'ajoute que presque toutes les « grandes » (en nombre d'articles) éditions de Wikipédia ont supprimé ce modèle. Les anglophones ont adopté la recommandation en:Wikipedia:No disclaimers in articles qui interdit ce type d'avertissement, de même que ceux pour contenu choquant, sensible etc. Je précise que sur Wikipédia en français, le Modèle:Sensible a été supprimé depuis longtemps : il serait cohérent de supprimer également le Modèle:Spoiler. Les hispanophones ne l'utilisent plus. Les italophones l'ont supprimé, les germanophones de même, les russophones de même, les catalanophones itou. Cette tendance lourde (à laquelle résistent également les lusophones et les néerlandophones) me semble frappée au coin du bon sens.

Thursday, November 10, 2011

Making a semantic property without linking

In Semantic mediawiki I wanted to add semantic functionality to a description in order to retrieve it in a semantic search but I dind't want a link on that description (far too long and meaningless as a title page).
  • In making a property without linking (Alex Brown) said: "sure thing - add the property has type:String or has type:Number to the property page."
  • I found on Help:Type String that "Values cannot be longer than 255 characters (if you use non-Latin characters, this number might be smaller). For longer strings, use datatype Text instead."

 To add a property to a page simply edit that page (for example the page "Property:Description") and enter "This property is a [[has type::text]]." It's magic, the links don't appear anymore!

Firefox moved to a rapid release cycle

Since spring 2011 Firefox has moved to a rapid release cycle  that's why we see so frequent releases.

 More explanations at  New development channels and repositories for rapid releases:
[Firefox had 3 updates channel]

  1. Nightly – builds created out of the mozilla-central repository every night. These are not qualified by QA
  2. Beta – builds created out of the mozilla-central repository, qualified by QA as being of sufficient quality to release to beta users
  3. Release – builds created out of the mozilla-central repository, qualified by QA as being of sufficient quality to release to hundreds of millions of people
Because the updates we put on the Nightly channel aren’t tested before they are offered to users, we use a different icon and name (“Minefield”) to indicate they are risky and not the stable Firefox most users expect.
While this approach has treated us well we feel there are some issues inherent in the current structure:
  1. The quality expectation for updates on the Beta channel is vastly higher than the updates on the Nightly channel
  2. Users on the Beta channel may not even know they are running pre-release (but hopefully decent) versions of Firefox
  3. Due to #1 above, development on the mozilla-central repository is frozen while we stabilize for an update to the Beta channel. This causes a huge backlog of patches and adds additional risk for the next beta
  4. 3rd parties must track Firefox development closely to know when a milestone they care about (such as feature complete, API freeze, or string freeze) is reached
  5. For developers, the tree rules are constantly changing on mozilla-central depending on when we last shipped an update from it
[Firefox has moved to 4 updates channels]
Because of these issues we came up with a modified process:
  1. Nightly – builds created out of the mozilla-central repository every night. These are not qualified by QA
  2. Aurora – builds created out of the mozilla-aurora repository, which is synced from mozilla-central every 6 weeks1. There is a small amount of QA at the start of the 6 week1 period before the updates are offered
  3. Beta – builds created out of the mozilla-beta repository, qualified by QA as being of sufficient quality to release to beta users
  4. Release – builds created out of the mozilla-release repository, qualified by QA as being of sufficient quality to release to hundreds of millions of people

Wednesday, August 10, 2011

Nokia slide 6700 N memory problem

Had the problem, posted the solution here: nokia forum:

I performed the "3 fingers reset method" explained here in French:comment ca marche.

Stop the phone remove the sim card.

phone swtiched off, press the following keys together - all at the same time :

the key [3]

the key [*]

the [green key to pick up a call]

Press shortly the [turn on key] , lift it up again as ssoon as the phone vibrates and the nokia startup tune comes. keep the other three keys pressed until a prompt to change the date comes. My phone was reseted and the anoying memory problem was removed.


Thursday, August 04, 2011

Luc Charpentier

Luc Charpentier donne actuellement un cours de théâtre d'improvisation au théâtre les feux de la rampe à Paris.
Il avait co-écrit le scénario de La Grosse caisse en 1965. Aussi mentionné sur ImoDB.
La page Myspace de Luc charpentier mentionne les mises en scenes auxquel il a participé:
Principales mises en scènes :
  • « Le nez » de Nicolas GOGOL (petit théâtre Apollo)
  • « Flon Flon » opéra bouffe show de Jacques ESTEREL (th. Mouffetard)
  • « Six hommes en question « de Frédéric DARD, premier assistant de Robert HOSSEIN (th. Antoine)
  • « Voulez-vous jouer avec Moâ ? « de Marcel ACHARD (th. Maurice Ravel)
  • « Quatre contes tragiques Japonais « d’après des NO de ZEAMI et MISCHIMA. (Th. Maurice Ravel)
  • « Chaînes » et « le drame des constructeurs » de Henri MICHAUX (th. Maurice Ravel)
  • « Il y a des salauds qui pillent le cœur des femmes « de Roger LOMBARDOT. (Alambic Studio Théâtre).
  • « Des Haricots Rouges de toutes les couleurs » Tournée en France.
  • « Les Haricots Rouges à Paris » (Auditorium des Halles et Auditorium Saint germain).
  • « Le bleu de l’eau de vie « de Carlos SEMPRUN MAURA (Alambic Studio Théâtre).
Il a animé l'Alambic studio théâtre.

Dans ses cours de théâtre: "L'enseignement se fait au travers de la méthode Stanislavski (Actors Studio - intériorisation) en alternance avec la méthode Brechtienne (distanciation - extériorisation), conjuguées à une méthode propre au Charpentier Art Studio (le contrat) qui permet de dégager le « vers quoi » (la direction singulière du spectacle et des personnages) et le « comment » (la manière d'interpréter de chacun en convergence avec la direction).
Elle permet également de développer le sens de la perception. "

Wednesday, July 27, 2011

Ubuntu update to 10.4 LTS a little disk drive issue

I finally upgraded Ubuntu to version 10.04 LTS. It works a lot faster to load PDFs for example. I'm writing this post from the upgraded system.

File upgrade and cleanup went well, I always choose default options.
There was just one little issue at startup:
"ubuntu disk drive for /media/sdb1 not ready yet or not present."

I could skip this with the "S" key and start the system alright. Hoever I thought it would be anoying to press this S key in the future at each startup. Thanks to this forum thread (where a very angry guy speaks) and this other site. I found the fix was to edit the file system table.
The following command starts the editor:
sudo gedit /etc/fstab

Then I commented out the line corresponding to this - inexisting - file system.
#/dev/sdb1 /media/sdb1 ntfs defaults 0 0

I saved the file and now I'm about to restart my computer.

Wednesday, June 22, 2011

Blank the screen in powerpoint to avoid divided attention

When the scientist presents: "Keep what the audience sees in sync with your speech [...] We, human folks, are not very good at doing two things at once when our senses are pulling us in different directions.[...] Blank the screen (B-Key or black slide)."

Thursday, June 16, 2011

Typing speed test

I just did this typing speed test: 12% of my typing time is lost due to mistakes.


Click on the image to see a screen shot of the test results.

Monday, May 30, 2011

Video editing with PiTiVi

I'm trying PiTiVi under Ubuntu Linux.
The goal is to edit a screencast, a video recording of my screen output and to add a background music.
I have the original video in AVI format from windows, that is
Saving, export formats of the video to the same format doesn't produce good results.
I tried saving with ogg format and got better results.
I have to figure out which ogg codec is better suited for my needs.

Multi layer editing
To unlink sources, select one or more sources. If it is linked, the unlink tool will become active. Clicking the unlink tool will break the link between it and any sources to which it is linked. If the sources to which it is linked are in turn linked to other sources, they're links will be left intact (unless they too are in the current selection).
I edited the audio with audacity, removed some noise and cracks. I'm now trying to insert the audio back in the video file.

Monday, March 28, 2011

How-to Delete an Oulook autocomplete address

To delete an adress in the Auto-complete list of Outlook, press the delete key. Trick found on that forum:

>I do not use auto-complete, it has been disabled. Yet when I type in any
> letter in the 'To' box, a whole list of email addresses that I've used
> anytime in the past two years appears. I don't want any names to appear.
> Please help me. Thanks.

You can delete them from that list. Just tap the delete key when the list
appears, and the highlighted address will disappear. Keep deleting until the
list is empty.

Tuesday, March 08, 2011

OpenOffice find function returns error when nothing is found

I wanted to sort operations on my bank sheet. I thought I'd extract the value at the end of a row (contained in cell D4) according to the first word (the word "transfer" for example) in a cell at the begining of the row (Cell B4). So I used this formula
=IF(FIND("TRANSFER",B4),D4,"")
If the culumn B4 contains the word TRANFER, this will return the value of column D4
  • But the problem is that if the word is not present, then the function FIND returns an error #value!
  • The solution is to use the ISNUMBER() function, to avoid that error. The function becomes something of the sort:
=IF(ISNUMBER(FIND("TRANSFER",B4)),D4,"")
I found this solution on the OpenOffice wiki.

Wednesday, February 23, 2011

if (window.focus) window.focus()

Object detection The whole point is that if you want to use the array document.images, first check if it is supported. If you want to use the focus method of the window, first check if it is supported.

If you always use object detection, your scripts will never generate any error messages, although they might not work in certain browsers.

Thursday, February 17, 2011

Incremental and Differential backups

What's the difference between differential and incremental backups (and why should I care)?
Most of the information on a computer changes very slowly or not at all. This includes the applications themselves, the operating system and even most of the user data. Typically, only a small percentage of the information in a partition or disk changes on a daily, or even a weekly, basis. For that reason, it makes sense only to back up the data that has changed on a daily basis. This is the basis of sophisticated backup strategies.

Differential backups were the next step in the evolution of backup strategies. A differential backup backs up only the files that changed since the last full back. For example, suppose you do a full backup on Sunday. On Monday you back up only the files that changed since Sunday, on Tuesday you back up only the files that changed since Sunday, and so on until the next full backup. Differential backups are quicker than full backups because so much less data is being backed up. But the amount of data being backed up grows with each differential backup until the next full back up. Differential backups are more flexible than full backups, but still unwieldy to do more than about once a day, especially as the next full backup approaches.

Incremental backups also back up only the changed data, but they only back up the data that has changed since the last backup — be it a full or incremental backup. They are sometimes called "differential incremental backups," while differential backups are sometimes called "cumulative incremental backups." Confused yet? Don't be.

I think it's bad practice (see my post on googlification) to link to the first result I found on google for the search "incremental differential". But what the hell! That explanation was satisfactory to me!

Monday, January 17, 2011

View your Google calendar in Outlook 2007

I was looking for a way to see my google calendar from work and I found this: View your Google calendar in Outlook 2007. It seems to work.