2014年8月30日星期六

How to completely uninstall Enthought Canopy on Mac OS

1. From Canopy preferences menu, Unset Canopy as your default Python.

2. Remove the following directory:

  •     /Applications/Canopy.app  
  •    also you can uninstall it by using mouse operation "Click".

3. Remove the residual files:
    sudo rm /Users/<your_username>/Library/Enthought

4. Remove the hidden folder:

  •     ~/ls -a   # listing all the files and folders including hidden one
  •     sudo rm ~/.canopy


5. After uninstalling Canopy, if you got the following messages when turning on the terminal:
-bash: /Users/<your_username>/Library/Enthought/Canopy_64bit/User/bin/activate: No such file or directory

You can solve this problem by

  •     ~/ls -a     # listing all the files and folders including hidden one
  •     sudo vi ~/.bash_profile     # opening the bash_profile by vim
  •     Keyboard operations: "ESC" and "i"     # insert mode
  •     Removing the lines which contain the offending file names.
  •     Keyboard operations: "ESC", ":wq"    # Save and exit

Weiqi: how difficult it is to make a computer compete against a human

A brief overview of Weiqi:
Weiqi is a strategy game where two players take turn placing stones on a board, which is wildly popular in China. There are only two types of stones: black stones and white stones.


After Deep Blue defeated Garry Kasparov in 1997, Time Magazine presented a new challenge: Let the computer battle with human. 

Peter Norvig in Google pointed out that even plenty of experts are invited, a hundredfold hardware, software, using correct machine learning algorithms, combined with the achievements of neurological science, it may not be able to reach the computer "Deep Blue" in terms of achievements in chess. Now Chess-playing softwares can compete with the best humans, however even strong amateurs can beat the top Weiqi-playing programs, why? There are three main reasons for this:
1. Game-tree complexity: there are about 10123 possible games in Chess. As for Weiqi, the American Weiqi Association reckons there are 10^700 (>>10123) possible games. In fact, numerical estimates show that the number of possible games of Weiqi far exceeds the number of atoms in the observable universe.

2. Lack of a good heuristic: Chess programs are able to evaluate quite accurately and quickly whether a given position is better than another one. On the contrary, no good heuristic has been found for Weiqi yet.
3. Pattern-recognition: strong Go players rely heavily on recognizing the shapes the stones take. There are too many of them for a computer to try to recognize in a game timeframe, and humans are much better than them at this.

Time Magazine predicted that the computer will use one hundred years or even longer to defeat humans on Weiqi, it seems be a forgone conclusion. But recently, Computer Crazy Stone which is designed by Prof. Remi Coulom of Computer Science at the Third University of Lille, France defeated Ishida Yoshio, a Weiqi master has won five titles. Precisely, Ishida had a four-handicap, this is an unfair duel, and also he is not in his peak condition. However, Crazy Stone is quite an achievement.

The use of randomly played games helped Crazy Stone get much stronger. Crazy Stone adopted the Monte Carlo method. It was found that the best way to evaluate a position is to play, from this position, a lot of games where each player puts stones at random on the board. Norvig in Google explained that this algorithm is an important innovation. After 20 steps, we can not say for sure who will win the game, and so finally we used the Monte Carlo method to determine the position’s score simply by the percentage of won random games. The computer begins with a prior probability distribution for every possible move. It picks one according to this distribution, plays a random game from the corresponding position and uses the result to update the probability for this move. It then selects another possible move according to the updated distribution and so on. So it learns during the game and the randoms play-outs that some kind of responses to his opponent’s moves are likely to have a bad result, and assigns them a lower probability.

It is reasonable to believe that, given time, Crazy Stone will become stronger and stronger and it seems that the prophecy from Time Magazine is soon to be dashed. 



2014年8月28日星期四

How to uninstall Python 2.7 (installed by yourself) on a Mac OS



1. Open the terminal.

2. Remove the Python 2.7 framework:
    sudo rm -rf /Library/Frameworks/Python.framework/Versions/2.7

3. Remove the Python 2.7 applications directory: 
    sudo rm -rf "/Applications/Python 2.7"
    
4. Remove the symbolic links in /usr/local/bin that point to Python 2.7:
    cd /usr/local/bin
    ls -l . | grep '../Library/Frameworks/Python.framework/Versions/2.7' | awk   '{print $9}' | xargs sudo rm

5. Back to the system default Python:
    cd /Library/Frameworks/Python.framework/Versions
    sudo rm Current
    sudo ln -s /usr/bin/python Current

PS: If you do not carry out Step 5, then there will be an error when you start python in the terminal.

JCR2013: Fractional Calculus and Applied Analysis

According to Thomson Reuters 2013 Journal Citation Reports SCI Edition.
FRACTIONAL CALCULUS APPLIED ANALYSIS.Impact_factor = 2.974.
This is the first time that "FRACT CALC APPL ANAL" receives these metrics
officially, rank 4/95 in category Mathematics, Interdisciplinary Applications,
and rank 5/250 in category Mathematics, Applied. Although it is not ranked
in "Mathematics" (pure, where it would be most suitable classification), the
data from JCR show that it can be also at 4th place (of 300), after "Commun
Pur Appl Math", "J AM Math Soc", "Acta Math (Djusholm)", and before the next
journals in the list as "Ann Math", "Fixed Point Theory", "Found Comput Math",
"Invent Math", "Mem AM Math Soc", "Duke Math J".

Congratulations!!! :)

PS: FCAA.MCQ (Mathematical Citation Quotient) = 0.50.
There is still much roooom for improvement. :)