Regular News

11 Sep 2008 21:53

Hello,

today is my birthday. Some of you asked… I was born 11 September 1987, so I'm 21 years old now. I'm just back from concert of some local guitar bands. I received nice gifts today, like a chair (named "Chef"), a Children Of Bodom t-shirt (thanks squark and his half), a chestnut (or kasztan if you wish) and I was going to be gifted a present from my girl, but unfortunately, she learns for her exam, so we'll meet tomorrow. I have no idea what the gift would be and I'm very curious about it.

Other news: I have passed the object DB in Python. The caching is just as fast as running query in a few seconds instead of 4 minutes in certain situation, so this seems a lot, and as a matter of fact, this is only a prototype of caching mechanism.

Nature (as some flowers) highers the work efficiency, so I set a ladybird as my new wallpaper. It motivates me.

I have though of my future (i.e. what to do AFTER being a successful programmer) being asked by my girl. I would like to manage some project (I believe I would be good in it).

And a time for confession: I really really love my Marta, and I will be very happy to be her beloved husband some day.

This is the end of the birthday blog post. The next will be here in year I hope.

The next post will be in Polish and will be about binary formats, helping people with them and Wikidot pro features. Keep tuned folks.

Comments: 3

Python Database: The Work Continues

28 Aug 2008 21:36

Today more work was done by me on the object oriented database implemented in Python.

I dealt with some problems I came across like proper object encapsulation. Now, my database allows any object to be stored in it, even of classes that are internally used by my database.

I implemented "." and "WHERE" operators, which seemed the worst, because they needed working environmental stack.

Now comes, what's the most individual — optimizing things with query cache. Actually it's not a query cache, but rather a evaluateNode cache, but this works very similar (the only difference is that the evaluateNode cache is more deep in operation and can be used inside of queries. This means it can accelerate the processing even for one query!

More work will come for sure on this, because the cache seems to be really tricky with such a flexible database model we've assumed.

Keep tuned for more news

Comments: 1

Object Database In Python - Day 2

16 Aug 2008 16:12

Hello again,

as pointed in the previous day comment, there is another IDE for developing in Python, which is BoaConstructor. As a matter of fact, I haven't taken that into consideration, because it was told it is a IDE for GUI development. As I was not about creating a GUI, this was completely skipped.

My impressions of the IDEs:

  • pida, geany, drpython — interesting, but not worth a try for me
  • eric — good overall, but raises many dialog boxes with information of exceptions. These are fatal and are about the GUI, so you have to click OK and continue working

I tried the Eric first, because it was written as a really good program. I like it, but it is not polished and would never be bought (if commercial) by anyone:

  • the support for SVN is really tricky
  • the GUI is really not intuitive — no "delete a file" or "new file (here)" in the navigator context menu
  • the code completion is there, but not really so clever

for example, having the following code:

class aClass:
    def method(self, param):
        assert isinstance(param, list)
        param.

the IDE should know, that the param is a list and complete the list methods! I believe the PyDev plugin for Eclipse already did it when I last used it.

After trying all the listed IDEs I got back to Eric as one of two best Python IDEs tried by me (the second is PyDev).

Happy Pythoning
Your Piotr

Comments: 1

Starting Work On Object Database In Python

15 Aug 2008 10:08

Good morning everyone,

today I start working on object database to be implemented in Python. This is my individual project for my classes.

During the study-year I was taught how to parse sophisticated grammar with PLY (Python Lex and Yacc library). I've then learned how to then process the parsed queries, to get the results.

The database query language is similar to the SQL language. The difference is, we don't have definitions of tables and fields. Any object (row in table) can have fields other that other objects with the same name (of the same table).

This seems quite hard, but it has its pros.

Moreover we've analyzed the following query using the simple parsing and processing:

SELECT employee.salary WHERE employee.salary > AVG(employee.salary);

now, having as much as 10000 employees, using the standard processing, this would mean calculating the average (AVG) from ALL salaries for EACH of the 10000 employees.

So the teacher proposed to use tree decoration, to mark the branches of the query syntax tree, that can be run once (i.e. their value does not depend on the rest of the query).

I proposed to do it other way: to don't analyze the tree to much, but instead implement a sort of caching. Each time we try to get the AVG(employee.salary) we check whether this was already calculated, if not (only the first time we get the AVG), we calculate this and populates the cache with the value.

This has the following pros:

  • we can use the cache in successive queries
  • we don't have to decorate query trees — it's not Christmas here

Today work I start with selecting a Python IDE to work with. During the classes I used PyDev — the Python plugin for Eclipse IDE, but I believe there any many new choices out there now — after a few months:

  • eric
  • pida
  • geany
  • drpython

(all from Ubuntu default repository)

More IDEs I found with Google:

Comments: 2

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License