Monday, April 27, 2015

Atom not found symbol index for...

Turn off the strip optimization (-s).

The credit should go to some Chinese tech websites. Although I dislike searching in Chinese, but I found sometimes when you get stuck in some technical issues and become helpless with discussions on stackoverflow etc, they could be your last resort. =)


Friday, April 17, 2015

MatlabMPI



MPI_func('eval_bmaps_mpi',[40],{'localhost'},randomDirName('/share/project/shapes/harry'),mymaps,imnames,category,mymaps,SBDopts.path);

put config to get SBDopts.path

Monday, April 13, 2015

A Line Never Processed

It took me two hours to find out a bug in my code. At this time, two hours could mean a real saboteur. It is not something classic, but still it's worth marking down.

So I wanted to read 1000 lines from a huge file at a time, and I did the following:

while (true)
{
count := 0;
while (infile>> xyz && count <1000)
{
        do something with xyz;
        count ++;
}

do something;
if (count < 1000)
      break;
}
}

The code runs smooth, however it takes a long time for me to find out some lines are missing from the output.

Eventually I found out it all occurs at 

while (infile>> xyz && count <1000)

which means if count == 1000 it will still read another line to xyz but stops at the condition count<1000, and that line will never be processed.

Looks silly, but it does caused me a lot of panic. 

Wednesday, April 8, 2015

Ubuntu Launcher Stays Behind

Open your terminal by pressing Ctrl + Alt + T and type this following to solve this problem:
unity&disown

Emacs Parenthesis Highlight and Indent Region

Parenthesis Highlight:

M-x show-paren-mode RET
Indent Region:
C-M-\