Why does an architect need a Pet project?

https://ravendb.net). Oren talked about why, when looking for developers, he chooses those who work on personal Pet projects in their free time (https://ayende.com/blog/90113/if-you-dont-have-pet-projects-i-dont-think-i-want-you).

In this article, I liked the idea that the Pet project is a good indicator that a person has an enthusiasm for the profession. It is the enthusiasm of the worker that cannot be taught in any way – it either exists or it does not. In addition, such a project is a sign of love for what you do.

I thought: is the Pet project useful for an architect, or does this “trick” work exclusively with developers?

Architects are different.

Let’s start with the fact that at work I have to communicate with three “types” of architects:

  1. System Architect
    Works in a small product agile team, usually he combines the functions of the architect and the developer. One of his main responsibilities is to design the architecture of his digital product.

  2. Solution Architect
    He designs complex integration solutions, interacting with a large number of product teams. Such architects are distanced from the program code and in their work operate not with the internal design of the application, but with entire systems.

  3. Corporate Architect
    This specialist manages the architecture of the entire company as a whole, interacting with stakeholders and acting as a strategy execution driver. It is the farthest from the program code.

With a system architect, everything is clear – this is such a “developer with additional abilities”, for whom the Oren Eini method works almost always, because the ability to write code is one of the main skills of this specialist. But with a solution architect and an enterprise architect, the situation is different.

Why does an architect need a Pet project?

It is useful for an architect to develop his Pet projects in order to:

Keep abreast of current technologies

Technology stacks change and evolve all the time. And if 10 years ago it was cool to make applications in a classic service-oriented architecture, now we cannot imagine a modern application without microservices. Technologies that make it easier to build applications of this class are also changing: database servers, distributed caches, message brokers, integration environments, and so on.

A modern architect is one who knows and understands technologies well and can design solutions that meet the requirements of reliability, availability, and scalability. And the Pet project is a great opportunity to play around with these technologies. For example, I personally know architects who set up small Kubernetes clusters at home to solve machine learning problems.

Know how to talk to developers

Former Allianz Chief Architect Gregor Hohpe in his article The Architect Elevator – Visiting the upper floors https://martinfowler.com/articles/architect-elevator.html talks in an accessible way about the role of an architect as a link between top management and technology teams. Such a specialist should be able to communicate with both high authorities and developers.

Having the opportunity to get into the shoes of a developer while creating your Pet project is a good way to understand how a developer thinks. This makes it easier for the architect to communicate with the team in the same language.

The Pet project also helps keep you grounded in order to avoid becoming an Ivory Tower architect, designing solutions that are impossible to implement. By the way, Asanka Abeysinghe from WSO2 in her article https://blog.architect2architect.com/an-architects-journal-skills-4e69c346383f about the key skills of an architect, especially highlights Implementation – the ability to work with code.

Avoid burnout

In the era of the pandemic and remote work, the likelihood of emotional burnout is especially high. For me, one of the main causes of burnout is the complication of getting feedback due to the decrease in the intensity of communication in a remote team. Architects often suffer from the fact that too much time passes between the adoption of an architectural decision and its implementation in production. And the more systems-products are involved in the solution, the longer this pause is delayed.

There are many studies on the Internet on this topic (https://habr.com/ru/company/habr_career/blog/437264/), whose authors unanimously emphasize one fact: programming is just as good a way to deal with burnout as music or sports. And programming is a great exercise for the mind.

So, there are more than enough reasons to “have fun” with your Pet project. The question remains – where to get the idea for the project? I will share my experience.

Lego robot – cat hunter

Five years ago, I bought my 9-year-old daughter a Lego Mindstorm set, a robot building game platform. With it, you can collect and program various interesting things.

Building Mindstorm nxt
Building Mindstorm nxt

At first, it was extremely interesting to play with her, especially with children, but over time, this interest began to fade. I wanted to breathe new life into the toy. There was a task: with the help of a robot to build a map of places in the apartment where our cat named “Squirrel” likes to sleep. According to my idea, the robot had to go around the apartment and, when finding a cat, mark on the map the places where he met the “object”.

Project phase #1: Identification of technical feasibility

It turned out that on Lego Minstorm EVA you can install Linux with Java, which has an API for controlling the robot. You can also connect a USB camera and a WiFi adapter to it. Therefore, there should be no problems with accessing the network and obtaining images for recognition.

Phase 2 of the project: Coming up with the architecture

Initially, I decided to make a simple layered architecture with a smart robot and image recognition using the Microsoft Azure Vision API.

Architecture "Version 1"
Architecture “Version 1”

I made a client using QT, a simple HTTP server was raised on the robot, and the code for interacting with motors, sensors and a camera was written in Java.

However, this architecture was not very efficient. An unexpected problem turned out to be the battery life of the robot – performing many tasks, it very quickly “ate” the battery charge. Therefore, I had to move everything, not related to the control of the robot’s hardware, to an external server.

Architecture "Version 2"
Architecture “Version 2”

This is what the final architecture looks like.

What happened

In the final tests, the robot looked like this:

Testing the algorithm for building a map and bypassing the premises
Testing the algorithm for building a map and bypassing the premises

Did you manage to implement my idea? Unfortunately no. I taught the robot to walk around the room and even recognize the cat, but there were too many “buts”. The motors of the robot were too noisy, they frightened the cat, which ran away whenever a mechanical “sentinel” appeared. This result, however, did not upset me too much, because in Pet-projects the process gives no less pleasure than the result.

car village

I am working on the second project now. While relaxing at the dacha, an idea was born – to make a service that counts how many people are now in our village. At the same time, you can find out in a couple of clicks – have the neighbors arrived at the dacha or not yet?

At first it seemed to me that it was easy to do this – there was only one entrance to the village and it was equipped with a video surveillance camera. The point is small – connect to it and count the number of cars that entered the village and left it.

Here are the architectural solutions (ADR) I used in this project.

ADR 1 How to count cars?

There are two options: to recognize the cars themselves and to distinguish between their license plates.

The advantage of the first option is that it seems easier. But I want to understand whether a car enters or exits. In addition, such a scheme will not give information about whether a particular neighbor arrived? Therefore, I chose the option with number recognition. To do this, we will use the well-known solution https://www.openalpr.com/ .

OpenALPR is an open source license plate recognition library written in C++ with links to C#, Java, Node.js, Go, and Python. The library analyzes images and video streams to identify numbers. The output is a textual representation of any license plate characters.

ADR 2 How to make a server and where to host it?

I didn’t want to mess with the clouds (yes, it’s a pity for the money for a subscription). Therefore, I decided to choose a solution that will allow me to host the service right in the country.

Electricity in the village periodically disappears, so you need to think about the smooth operation of the service.

I settled on the Jetson Nanohttps://www.nvidia.com/ru-ru/autonomous-machines/embedded-systems/jetson-nano/ ) is a single-board from NVidia with the ability to run neurons. The advantage is that it can be powered from a powerbank.

Battery life test
Battery life test

ADR 3 How to write a service?

The service for my goal should be lightweight, consume little processor power and not slow down. Therefore, as a development language, I chose C ++ and a common framework for writing embedded services https://pocoproject.org/. The framework is up-to-date, fast and used by a large number of well-known companies.

Current state – I have developed a prototype that can process pictures from the camera and makes attempts to recognize the license plates of passing cars. Unfortunately, the resolution of the camera does not make it possible to recognize the license plate with sufficient quality. And it seems that I will have to dive even deeper into the technologies for identifying objects in the image. But it only makes me happy, because the goal of the project is to learn something new for myself.

Should I start a Pet project?

What conclusions did I draw about the benefits of Pet-projects specifically for myself:

  • They allow me to remember my programming skills, because writing the code yourself is cool!

  • They encourage me to dive into areas that are new to me, such as machine learning.

  • They allow me to apply the skills of an architect “in everyday matters.”

And remember that there are a lot of ideas for your Pet projects around, you just need to take a closer look. =)

Do you already have experience in running a Pet project? Tell us about it in the comments. If you are just planning to start such a project – share your ideas, we will discuss them together!

Similar Posts

Leave a Reply