atlas news
    
Beauty of Imagination : Python
20  novembre     09h03
The advantages of HTML as a data model over basic declarative ORM approach
   Very often, backend devs don’t want to write code. For this, we use one trick : derive HTML widget for presentation, database access, REST endpoints from ONE SOURCE of truth and we call it MODEL. A tradition, and I insist it’s a conservative tradition, is to use a declarative model where we mad the...
06  novembre     08h50
The crudest CRUD of them all : the smallest CRUD possible in 150 lines of python
   Right now, I am on a never ending quest that requires me to think of building a full fledge MVC controller : an anti jira tracker that would favours HARD CHECKED facts over wishful thinking. For this to begin, I am not really motivated in beginning with a full fledged MVC Model View Controller à ...
29  octobre     13h24
Is chatgpt good at generating code for tuning a guitar ?
   I was on a french speaking IRC chan bragging a tad about how I was doing a guitar tuner and paying attention to not fall into the pit of confusing precise and exact figures as a random computer engineer. Science he was a patented CS engineer he wanted to prove me that my new guitar tuner was...
22  octobre     09h49
Tune your guitar with python
   Today’s exercice is just about turning a very nice example of the python soundevice module into something that works for me to help me tune my bass. Long story short, I suck at tuning my instrument and just lost my tuner... This will require the python module soundevice and matplotlib. So in order...
21  octobre     08h51
Hello world part II : actually recoding print
   In part I we explored the pre requisite in order to code print : having a grasp on the framebuffer. Here, we are gonna deep inside one of the most overlooked object oriented abastraction : a file and actually print what we can of hello world in lines of code. The file handler and the file...
20  octobre     10h01
Revisiting hello world : coding print from scratch part I
   The hello world example is about standing on the shoulders of the giant and learn how to use function as tools. Most coders will use print during their whole life without actually coding it. However, it is a fun exercise. The framebuffer Given you are on linux you probably have a device...
17  octobre     11h48
3D ploter in python-tk with matplotlib.
   Wishing to prove my assertion wrong on python tk that piping python directly into tk tcl interpreter is simple I tried to contradict myself by making a full GUI in matplotlib. Because, if you are not aware : matplotlib supports multi target Wx, Qt, gtk, tk, html multi platform widgets Button,...
07  octobre     14h04
Writing an interactive tcl tk interpreter proxy to wish in python
   Maybe, you want to experiment small stuffs in wish the tcl tk interpreter because of a post claiming that direct python tcl tk is simpler in some simple cases than tkinter. As a convinced tkinter FreeSimpleGUI user, I see this as an extreme claim that requires solid evidences. When all is said...
06  octobre     11h29
Bidirectionnal python tk by talking to tk interpreter back and forth
   Last time I exposed an old way learned in physical labs to do C or python tk like in the old days: by summoning a tcl tk interpreter and piping commands to it. But what fun is it It’s funnier if the tcl tk interperpreter talks back to python :D as an hommage to the years awaited TK versions...
05  octobre     07h48
Simpler than PySimpleGUI and python tkinter: talking directly to tcl tk
   Well, the PySimpleGUI rug pulling of its licence reminded me how much dependencies are not a good thing. Even though FreeSimpleGUI is a good approach to simpler tk tcl binding in python : we can do better, especially if your linux distro split the python package and you don’t have access to...
24  septembre     08h54
PySimpleGUI : surviving the rug pull of licence part I
   I liked pySimpleGUI, because as a coder that likes tkinter the Tk Tcl bindings and as a former tcl tk coder I enoyed the syntaxic sugar that was avoiding all the boiler plates required to build the application. The main advantage was about not having to remember in wich order to make the pack...
24  mars     18h32
Modern Computer Science is obscurantism disguised as science
   Recently I decided to get back to the basics and question my use of classes frameworks. I tried to find a definition of the word framework but weirdly this word is a tautology, no one knows what it is, but it refers at itself for something people use to get the work done through the use of...
20  mars     01h28
I still find with the examples used for teaching OOP counterproductive
   After the stupid example with the taxonomy of the species car employees that makes you do a lot of inheritance one of the valid use case for OOP is D geometry : points amp; rectangles. This is the python example in wiki.python.org https: wiki.python.org moin PointsAndRectangles Don’t worry,...
23  septembre     22h29
Querying complex unknown database with python
   In my job, I sometimes have to deal with web applications that are pointing to half a dozen databases with an overall of more than tables. Not to say it can be complex, but sometimes it is : So I made a small script using of my favourite technologies to deal with that: graphviz, and...
20  septembre     18h49
Using python to visualize randomness
   Heard of randomness What is random: something that given a serie of chronological events happening after one another whatever long the time serie is, we cannot predict the future. Two kinds of events are random; purely random events stochastics or mathematically deterministic equations that...
19  avril     17h55
So I wrote a Proof of Concept language to address the problem of safe eval
   I told fellow coders: hey I know a solution to the safe eval problem: it is right under my eyes . I think I can code it in less than hours from scratch. It will support safe templating... Because That’s the primary purpose for it. TL; DR: I was told my solution was overengineering...
16  avril     01h10
Eval is even more really dangerous than you think
   Preamble, I know about this excellent article: http: nedbatchelder.com blog eval really is dangerous.html I have a bigger objection than ned to use eval; python has potentially unsafe base types. I had this discussion with a guy at pycon about being able to safely process templates and...
04  octobre     18h16
An opinionated versioning system based on mapping versions string to numbers in weird base
   While we have a convention in python for numbering: http: legacy.python.org dev peps pep We can mostly say that version numbering thanks to Windows has shed an interesting spotlight on version comparaison. They are to tenants of version handling: the naïves who consider...
02  octobre     16h31
Perfect unusable code: or how to modelize code and distributivity
   So let’s speak of what and un deterministic code really are. I am gonna prove that you can achieve nearly chaotic series of states with deterministic code o Definitions: Deterministic: code is deterministic if the same input always yield the same output Chaotic: a time serie of value is...
13  décembre     22h23
Auto documenting and validating named arguments
   In real life there are companies were keywords kw are prohibited, and others where positional arguments can stack up as high as seven. Let’s state the obvious concerning arguments: Human beings are flawed The positional arguments are fixed arguments. Some are mandatory others are...
04  décembre     20h28
Cross dressing on the internet and gender issues
   So the actual buzz is gender issues http: www.kathrineswitzer.com written about.shtml I dare say it is a non problem. But before let me tell you my story as a cross dresser ... on the internet. Once upon a time I signed up for a famous dating site. And as advised by a friend, I was told to...
26  octobre     00h22
Using signal as wires?
   Learning that signals were software interrupts in a book on Unix, I thought, hey, let’s try to play with signals in python since it is in stdlib The proposed example is not what one should really do with signals, it is just for the purpose of studying. Well remember this point it will prove...
21  octobre     18h59
My problem with Computer Science pseudo code
   I remembered opening books of Computer Science to learn algorithm when I began. And my first reaction was: it seems unnecessarily complicated like maths, but I must be an idiot since I learnt physics. So years later I reopened Introduction To Algorithms By Thomas H Cormen, Charles E...
16  octobre     18h10
Unicode is tough
   So today, I dared open a bug on python. Which at one point should make me feel mortified, since it has proven that I misunderstood what a character is. The point was in python . : fooâ bar File stdin , line fooâ bar SyntaxError: invalid character in identifier...
27  septembre     16h37
Fun with signal processing and ... matplotlib
   Well, I remember overhearing a conversation one day in a laboratory once years ago. Electronic engineers were proud to have helped their team to higher CDD resolution with a trick they published: they would use a median filter to filter out the photon arriving from the CDD from the...