加载中…
个人资料
spotofleopard
spotofleopard
  • 博客等级:
  • 博客积分:0
  • 博客访问:266,828
  • 关注人气:28
  • 获赠金笔:0支
  • 赠出金笔:0支
  • 荣誉徽章:
分类
锐博客
 
欢迎点击进入锐博客首页
博文
(2016-10-22 06:22)

我一直试图搞清诗为什么那么有诗意。一些看似平淡无奇的字词,从诗人的笔下写出来就像是经过精巧手工艺品的制造者,马上变成了一件艺术。人工智能倒是最近在这一领域有很大突破:深度神经网络在阅读过数十万字的诗以后就成为了诗人,可以写出一些像模像样的诗句来。不过我最近也小有发现,那些隽永的名篇,原来描写的其实大多是数学和物理现象。

​先看李白的《将进酒》,君不见黄河之水天上来,奔流到海不复回。君不见,高堂明镜悲白发,朝如青丝暮成雪。这里李白实际

阅读  ┆ 转载 ┆ 收藏 
(2014-11-08 01:05)
分类: 随笔

看见北京最近蓝的刺眼的天空,不仅想起小时候我所在小县城申请什么全国卫生文明城市。80年代的小县城那时还主要靠蹲坑式公厕解决问题,在检查团到来的前几天,厕所里面墙也刷了,地上垫上了沙子和石灰,还挺像回事,连到处爬的蛆都不见了。唯一的问题是检查团要来那天,我要去拉屎,在门口被一个带红袖箍的老大爷的给拦住了,非要让我去别处拉去。时代久远,我已忘了那泡屎最终拉在了哪里,但好像那个卫生文明城的称号确实拿到了。后来我要是再看见哪个城市自称卫生文明城,我就想:原来你们那也不让拉屎。


阅读  ┆ 转载 ┆ 收藏 
(2013-09-26 02:22)
标签:

民主

分类: 随笔
大山沟沟里的靠山屯已经通上了电好几年,家家户户都点上了电灯,有的还买了电视,--除了屯西头的老王家。就因为老王这一家,村里年年评不上先进,乡里怪罪下来,村长也很是恼火。
这天村长又来到老王家,老王的媳妇热情的招呼“村长来啦”,老王却一声不吭蹲在炕头抽着旱烟袋。村长又照例把“有了电,真方便,电灯电话电视机”说了一遍。老王也不回话,过了半天抽冷子冒出一句:“屯东头老印他们家倒是通电了,那咋还吃不饱饭?”
“看你说的,那电也不管吃饭哪”,村长耐心地陪着笑脸。
“屯子里李秃子家也是通电了,脑袋也没见长出一根毛!”老王不为所动。
老王真能说笑话,那电也不管秃头啊”,村长依旧陪着笑脸。
“这也不管,那也不管,那我要它有屁用!”老王用烟袋锅敲敲炕沿,送客了。

听说电业局小张能说会道,人也机灵,村长又把小张请来试试。等小张热情洋溢的动员结束后,老王狠狠地吸了口旱烟,不紧不慢的说:“以前没有电,大伙也活了几千年了,听你恁说,好像没电还活不成了?头两天,西山的王二小放牛被掉下来的高压线给电死这
阅读  ┆ 转载 ┆ 收藏 
分类: 技术
I used to use jwplayer with shadowbox, but there are two issues there:
1. the license option of jwplayer is expensive
2. it doesn't playback flv video returned by php file. it keeps complaining: the playlist file does not contain a valid playlist

So I turned to flowplayer free version. But shadowbox doesn't support it out of the box.
Fortunately, it's pretty easy to fix. We only need to change flashvars passed to flowplayer.
Here's what it should be like:

We only need to modify the embedSWF and createSWF function in shadowbox.js to achieve this.
in embedSWF:

par.flashvars='config={';
if (flashvarsObj && typeof flashvarsObj === OBJECT) {
   
阅读  ┆ 转载 ┆ 收藏 
以人權衛士自居的美國政府對别國的人權狀況指手畫腳已经不是什么新闻了,问题是美国自己屁股也不干净,普通美国百姓生活在水深火热之中却还浑然不觉,令人痛心啊。那么美国政府为什么这么不惜余力,上窜下跳,颠倒黑白呢?无非是为了一小撮统治阶级的利益罢了。回头看看我们的近邻北朝鲜,百姓们每日沐浴在伟大领袖的温暖光芒中,如果我们非要一语惊醒梦中人,未免有些残忍,而且朝鲜的百姓未必就领你的情,可能还会骂你别有用心,狗拿耗子。

我们国务院最近发布的《美国的人权纪录》,真是一针见血啊。我们不妨一条一条剖析一下。
人權紀錄指出,美國選舉也不能充分體現全體公民的真正意志。在2012年美國大選中,僅有57.5%的選民參加了投票。只有57.5%?!令人发指啊!我们是多少来着?120%?
阅读  ┆ 转载 ┆ 收藏 
标签:

杂谈

分类: 随笔
I have a Zojirushi NP-HBC10 induction rice cooker for over 3 years. It worked very well, everybody likes the rice it made. But as you already guessed, it broke down a couple of weeks ago. The symptom is that the LCD screen still displays clock, but nothing changes when you plug in the power. Of course it doesn't respond to any key press either.

I decide to fix it myself. but when I opened it up, it's definitely more complex than I expected from a rice cooker. It has 4 circuit boards: line filter, power supply, induction driving, control.



阅读  ┆ 转载 ┆ 收藏 
分类: 技术
1. generate your GPG key
gpg --gen-key
fill your information as required

2. prepare your application files. you can create a directory called my_app1.01 somewhere, if you plan to put your files under /usr/local/my_app on target machine, you copy all your /usr/local/my_app/* to this directory, while maintaining the directory structure. Then create file my_app1.01/DEBIAN/control

Package: my-app
Version: 1.01
Architecture: all
Section: misc
Priority: optional
Depends: coreutils
Maintainer: FirstName LastName
Description: my ubuntu application


3. generate .deb package
dpkg-deb --build my_app1.01

4.sign your package
debsigs --sign=origin my_app1.01.deb

5.determine your keyid:
gpg --fingerprint

Key fingerprint = .... 1234 5678 9abc def0 <== your key id

export your public
阅读  ┆ 转载 ┆ 收藏 
标签:

棕榈泉

杂谈

分类: 浮光掠影






阅读  ┆ 转载 ┆ 收藏 
标签:

无损

连接

jpeg

杂谈

分类: 技术
working flow of JPEG compression
1.RGB to YUV space
2.8x8 block DCT
3.Quantization
4.Huffman Encoding
Refer to Wikipedia for more details.JPEGsnoopis a very useful tool.

I wanted to add a databar to bottom of a large JPEG image(20M pixels), without decompressing it.
1. use libjpeg to get DQT of origianl image: jpeg_read_header()
2. use libjpeg to find DC coefficients of last block of original image. : JPEG_read_coefficients()
3. generate bitmap of the databar, then encode it using libjpeg, make sure the compression parameters are consistent with original image, such as DQTs, vertical sampling factor.
4. recalculate first block's DC values of databar,encode again.
5. copy the rest of databar encoded data
6. modify SOF0 image size

阅读  ┆ 转载 ┆ 收藏 
(2012-04-20 22:56)
标签:

育儿

分类: 我家
Talking to Evan is like opening a floodgate.
'Who is you favorite girl in your class?', I asked.
'Sydney. Because she let me use her crayons. Nathan let me use his crayons too, but Sydney let me use it first. Nathan has 96 crayons! for real! 6 packs! Guess what? if I gave him 4 crayons, he will have 100! He even has a glistering crayon, for real! trust me! Sydney has brown hair, and peach skin. Not regular peach, light peach. But I am not going to marry her. When I see her when I am in college, I have to tell her we were in same class, so she can remember me. I like her because she lets me use her crayon, but I am not going to marry her. Because I have to marry Mommy.'
阅读  ┆ 转载 ┆ 收藏 
  

新浪BLOG意见反馈留言板 电话:4000520066 提示音后按1键(按当地市话标准计费) 欢迎批评指正

新浪简介 | About Sina | 广告服务 | 联系我们 | 招聘信息 | 网站律师 | SINA English | 会员注册 | 产品答疑

新浪公司 版权所有