Sugree

Main menu

  • About
    • Self
  • Project
    • jibjib
  • English
  • Thai

Python

Parallel Programming in Python

Submitted by sugree on Thu, 07/03/2008 - 23:19.
  • Education
  • Python
  • Thai

สืบเนื่องจากตอนลองเขียน MPI ด้วย Pythonเมื่อต้นสัปดาห์ เพื่อให้เห็นผลชัดเจนก็ลองเขียนจริงๆ จังๆ ให้มันแก้ปัญหาได้ซักข้อ ขอสัมผัสอารมณ์ ความรัก ความรู้สึกซักหน่อย แล้วก็ได้เรื่องจริงๆ โจทย์ก็อันเดิม LCS อันแสนธรรมดา

  • Add new comment
  • Read more

Once upon a time with Flickr API

Submitted by sugree on Fri, 03/21/2008 - 23:44.
  • English
  • Flickr
  • Hardy
  • Python
  • Ubuntu

After upgrading to Hardy, today is my first chance to run jUploadr to upload new photos to Flickr. But unfortunately, I couldn't see photo thumbnails. Actually, they were just black.

juploadr-1.1.2 dark thumbmails

Then I tried jUploadr 1.2 alpha 1 and the result was similar.

juploadr-1.2a1 dark thumbmails

So I had to find alternative solution other than jUploadr due to a bug in X.org. Anyway, I didn't find any good one so I decided to try flash uploader.

  • 3 comments
  • Read more

Python Newbie

Submitted by sugree on Fri, 01/11/2008 - 00:01.
  • Joke
  • Python
  • Ubuntu
  • Thai

file encoding

(10:42:18 PM) mimoly: sugree, คือ จะถามหน่อยค่ะ พอดีเขียน.py ไว้อัน แล้วใส่ภาษาไทยลงไป ทีนี้พอมาเรียกเป็นสคริปต์ของxchat แล้วมันไม่รองรับน่ะค่ะ
(10:42:34 PM) mimoly: มันไม่ยอมให้เรียกเลยล่ะ
(10:42:57 PM) mimoly: เลยอยากรู้ว่า python นี่ มันไม่ซัพพอร์ทภาษาไทยเหรอคะ
(10:43:06 PM) mimoly: หรือว่าเป็นที่เอ็กซ์ฉะ
(10:43:25 PM) sugree: อ่า
(10:43:34 PM) sugree: ตอนเซฟบอกว่าเป็น utf-8 รึเปล่า
(10:43:46 PM) sugree: ใส่ magic เป็น utf-8 รึยัง
(10:44:40 PM) mimoly: magic คืออะไรเหรอคะ
(10:44:48 PM) mimoly: ข้าวเพิ่งหัดเขียนเอาวันนี้เอง
(10:45:02 PM) pFz[0]: อ้าว
(10:45:12 PM) pFz[0]: กำ
(10:45:27 PM) pFz[0]: นึกว่าเรียนมาแล้ว
(10:45:42 PM) sugree: # -*- coding: utf-8 -*-
(10:45:53 PM) sugree: ใส่แบบนี้ใน .py
(10:46:08 PM) sugree: เซ็ตที่ editor ให้เป็น utf-8 ด้วย
(10:46:18 PM) sugree: LANG ก็ได้
(10:58:29 PM) ***pFz[0] หาว หาว หาว
(10:59:14 PM) pFz[0]: หากระทู้ตอบแก้เซ็ง
(11:03:07 PM) mimoly: 8jt
(11:03:09 PM) mimoly: ค่ะ
(11:03:13 PM) mimoly: ลองแปปนะคะ
(11:07:28 PM) mimoly:  File "/home/mimoly/Documents/aaa.py", line 2
(11:07:29 PM) mimoly:      coding: utf-8
(11:07:29 PM) mimoly:            ^
(11:07:29 PM) mimoly:  SyntaxError: invalid syntax
(11:07:29 PM) mimoly:  Error loading module /home/mimoly/Documents/aaa.py
(11:07:53 PM) sugree: ใส่ให้เหมือนเป๊ะนะ
(11:08:00 PM) pFz[0]: ทำไมไม่สำเนาไปเลย
(11:08:03 PM) sugree: # -*- coding: utf-8 -*-
(11:08:06 PM) sugree: มี # ด้วย
(11:08:11 PM) sugree: ชิดซ้ายสุด
(11:08:31 PM) mimoly: อ่ะ
(11:08:33 PM) sugree: พวก -*- ก็เอามาด้วย
(11:08:41 PM) sugree: เค้าถึงเรียก magic ไง
(11:08:42 PM) mimoly: มันไม่กลายเป็นคอมเมนท์ไปเหรอคะ =w=
(11:08:49 PM) sugree: ใช่ มันคือ comment
(11:10:26 PM) mimoly: อ้ะ
(11:10:29 PM) mimoly: ได้แล้วค่ะ
(11:10:42 PM) mimoly: ขอบคุณมากเลยนะคะคุณsugree
(11:11:00 PM) mimoly: ใจดีเหมือนปู่พิ้งเลย =w=
(11:11:10 PM) pFz[0]: - -
(11:11:16 PM) ***pFz[0] ๑๒   ใคร ๆ ก็รู้
(11:11:33 PM) sugree: ฮ่ะๆ
(11:11:51 PM) sugree: เอาไว้รอ python 3k ก็ไม่ต้องใส่แล้ว
(11:12:21 PM) mimoly: ค่ะ *w*
  • 7 comments
  • Read more

Define unicode string in Python

Submitted by sugree on Thu, 12/27/2007 - 12:22.
  • Python
  • Unicode
  • Thai

เมื่อกี๊ได้รับการร้องขอให้อ่านข้อความแบบ unicode ให้ หน้าตาที่ให้มาเป็นแบบนี้

\u0e04\u0e23\u0e31\u0e49\u0e07\u0e17\u0e35\u0e48

เห็นแล้วคิดในใจ "ง่ายโคตร" ใช้ Python ดีกว่า แต่ดันสมองตื้อกระทันหันไปทำแบบนี้

s = '\u0e04\u0e23\u0e31\u0e49\u0e07\u0e17\u0e35\u0e48'
  • Add new comment
  • Read more
12next ›last »

Popular Tags

Assumption BarCamp BarCampBangkok birdnest BitTorrent BugAThon Creature Drupal DrupalCamp DrupalCampBangkok Education GnuCash Google Gutsy Hardware Hardy Health Java jibjib Joke OpenOffice.org Python Review SoC Social Network Trip TwittBKK TwittDay Twitter Ubuntu
more tags

Powered By

debian
apache
drupal
drupal.in.th
feedburner

© 2007-2008 Sugree Phatanapherom. Creative Commons [Feed Content / Comment]
RoopleTheme