Pull to refresh

Development

Show first
Rating limit
Level of difficulty

Checking Telegram Open Network with PVS-Studio

Reading time 7 min
Views 1.3K

Picture 3

Telegram Open Network (TON) is a platform by the same team that developed the Telegram messenger. In addition to the blockchain, TON provides a large set of services. The developers recently made the platform's code, which is written in C++, publicly available and uploaded it to GitHub. We decided to check the project before its official release.
Read more →
Total votes 30: ↑28 and ↓2 +26
Comments 0

How we made landmark recognition in Cloud Mail.ru, and why

Reading time 11 min
Views 2.4K


With the advent of mobile phones with high-quality cameras, we started making more and more pictures and videos of bright and memorable moments in our lives. Many of us have photo archives that extend back over decades and comprise thousands of pictures which makes them increasingly difficult to navigate through. Just remember how long it took to find a picture of interest just a few years ago.

One of Mail.ru Cloud’s objectives is to provide the handiest means for accessing and searching your own photo and video archives. For this purpose, we at Mail.ru Computer Vision Team have created and implemented systems for smart image processing: search by object, by scene, by face, etc. Another spectacular technology is landmark recognition. Today, I am going to tell you how we made this a reality using Deep Learning.
Read more →
Total votes 45: ↑44 and ↓1 +43
Comments 0

Handling Objections: Static Analysis Will Take up Part of Working Time

Reading time 5 min
Views 990
bugTalking to people at conferences and in comments to articles, we face the following objection: static analysis reduces the time to detect errors, but takes up programmers' time, which negates the benefits of using it and even slows down the development process. Let's get this objection straightened out and try to show that it's groundless.
Read more →
Total votes 33: ↑32 and ↓1 +31
Comments 0

Configuration of the Warnings Next Generation plugin for integration with PVS-Studio

Reading time 3 min
Views 1.6K

Picture 4


The PVS-Studio 7.04 release coincided with the release of the Warnings Next Generation 6.0.0 plugin for Jenkins. Right in this release Warnings NG Plugin added support of the PVS-Studio static code analyzer. This plugin visualizes data related to compiler warnings or other analysis tools in Jenkins. This article will cover in detail how to install and configure this plugin to use it with PVS-Studio, and will describe most of its features.
Read more →
Total votes 34: ↑33 and ↓1 +32
Comments 0

The best is the enemy of the good

Reading time 11 min
Views 1.2K

Picture 6

This article is the story how we once decided to improve our internal SelfTester tool that we apply to test the quality of the PVS-Studio analyzer. The improvement was simple and seemed to be useful, but got us into some troubles. Later it turned out that we'd better gave up the idea.
Read more →
Total votes 43: ↑41 and ↓2 +39
Comments 0

PVS-Studio Usage when Checking Unreal Engine Projects on the Windows OS

Reading time 10 min
Views 1K

Picture 2

This article focuses on the specifics of checking Unreal Engine projects with the PVS-Studio static analyser on the Windows operating system: how to install the analyser, check a project, where and how to view an error report.
Read more →
Total votes 32: ↑29 and ↓3 +26
Comments 1

Tips and tricks from my Telegram-channel @pythonetc, August 2019

Reading time 4 min
Views 1.6K


It is a new selection of tips and tricks about Python and programming from my Telegram-channel @pythonetc.

Previous publications


If an instance of a class doesn’t have an attribute with the given name, it tries to access the class attribute with the same name.

>>> class A:
...     x = 2
...
>>> A.x
2
>>> A().x
2
Read more →
Total votes 29: ↑27 and ↓2 +25
Comments 1

How to Make Emails and Not Mess Up: Practical Tips

Reading time 23 min
Views 3K


A developer, who first encountered generating emails, has almost no chance to write an application, that will do it correctly. Around 40% of emails, generated by corporate applications, are violating some form of standard, and due to this, there are problems with delivery and display. There are reasons for this: emails are technically more difficult than the web, and operating emails is regulated by a few hundred standards, as well as an uncountable number of generally accepted (and not as much) practices, whereas the email clients are more varied and unpredictable than browsers. Testing may significantly improve the situation, but materials that are dedicated to testing the email system, are practically non-existent.

Mail.ru regularly interacts with its users by email. In our projects, all the components responsible for generating emails and even individual mailings, are subject to mandatory testing. In this article, we will share our experience (learning from our mistakes).
Read more →
Total votes 40: ↑40 and ↓0 +40
Comments 2

Using PVS-Studio Static Analyzer in C and C++ Development for Embedded Systems

Reading time 4 min
Views 1.2K

This article will tell you how to launch analysis of an embedded project and how to work with the analyzer's report. The PVS-Studio analyzer supports a number of compilers for embedded systems. The current version allows checking projects built with one of the following compilers under Window, Linux, and macOS:

Read more →
Total votes 29: ↑27 and ↓2 +25
Comments 0

Get to Know the PVS-Studio Static Analyzer for Java

Reading time 4 min
Views 1.2K
Over the years, the PVS-Studio team has been developing the same-name static analyzer. At this point the analyzer represents a complex software solution, which provides the analysis of such programming languages, as C, C++, C# and Java on Windows, Linux and macOS platforms. Just recently the Java language joined the ranks of supported languages. The PVS-Studio analyzer has proved itself as a reliable tool among C++ and C# developers in quite some time, whereas for Java audience PVS-Studio is still a newcomer. Many haven't even heard of the analyzer, and those who had, aren't quite familiar with all its abilities. So in this article, I'd like to introduce PVS-Studio Java to you, talk about the ways to start it and its abilities.

Рисунок 3

Read more →
Total votes 28: ↑27 and ↓1 +26
Comments 0

Contextual Emotion Detection in Textual Conversations Using Neural Networks

Reading time 10 min
Views 3.7K

Nowadays, talking to conversational agents is becoming a daily routine, and it is crucial for dialogue systems to generate responses as human-like as possible. As one of the main aspects, primary attention should be given to providing emotionally aware responses to users. In this article, we are going to describe the recurrent neural network architecture for emotion detection in textual conversations, that participated in SemEval-2019 Task 3 “EmoContext”, that is, an annual workshop on semantic evaluation. The task objective is to classify emotion (i.e. happy, sad, angry, and others) in a 3-turn conversational data set.
Read more →
Total votes 37: ↑37 and ↓0 +37
Comments 0

PVS-Studio Looked into the Red Dead Redemption's Bullet Engine

Reading time 10 min
Views 4.5K
Picture 4

Nowadays there is no need to implement the physics of objects from scratch for game development because there are a lot of libraries for this purpose. Bullet was actively used in many AAA games, virtual reality projects, various simulations and machine learning. And it is still used, being, for example, one of the Red Dead Redemption and Red Dead Redemption 2 engines. So why not check the Bullet with PVS-Studio to see what errors static analysis can detect in such a large-scale physics simulation project.
Read more →
Total votes 34: ↑31 and ↓3 +28
Comments 0

AI-Based Photo Restoration

Reading time 7 min
Views 18K


Hi everybody! I’m a research engineer at the Mail.ru Group computer vision team. In this article, I’m going to tell a story of how we’ve created AI-based photo restoration project for old military photos. What is «photo restoration»? It consists of three steps:

  • we find all the image defects: fractures, scuffs, holes;
  • we inpaint the discovered defects, based on the pixel values around them;
  • we colorize the image.

Further, I’ll describe every step of photo restoration and tell you how we got our data, what nets we trained, what we accomplished, and what mistakes we made.
Read more →
Total votes 34: ↑33 and ↓1 +32
Comments 4

Security of mobile OAuth 2.0

Reading time 12 min
Views 14K
image

Popularity of mobile applications continues to grow. So does OAuth 2.0 protocol on mobile apps. It's not enough to implement standard as is to make OAuth 2.0 protocol secure there. One needs to consider the specifics of mobile applications and apply some additional security mechanisms.

In this article, I want to share the concepts of mobile OAuth 2.0 attacks and security mechanisms used to prevent such issues. Described concepts are not new but there is a lack of the structured information on this topic. The main aim of the article is to fill this gap.
Read more →
Total votes 34: ↑33 and ↓1 +32
Comments 0

The one who resurrected Duke Nukem: interview with Randy Pitchford, magician from Gearbox

Reading time 38 min
Views 3.6K
RUVDS and Habr continue the series of interviews with interesting people in IT field. Last time we talked to Richard «Levelord» Gray, level designer of popular games Duke Nukem, American McGee’s Alice, Heavy Metal F.A.K.K.2, SiN, Serious Sam, author of well-known «You’re not supposed to be here» phrase.

Today we welcome Randall Steward «Randy» Pitchford II, president, CEO and co-founder of Gearbox Software video game development company.

Randy started in 3D Realms where contributed to Duke Nukem 3D Atomic Edition and Shadow Warrior. Then he founded Gearbox Software and made Half-Life: Opposing Force, which won D.I.C.E in 2000. Other Gearbox titles include Half-Life: Blue Shift, Half-Life: Decay, Counter-Strike: Condition Zero, James Bond 007: Nightfire, Tony Hawk's Pro Skater 3, Halo: Combat Evolved and of course Borderlands.

The interview team also includes editor of Habr Nikolay Zemlyanskiy, Richard «Levelord» Gray, Randy’s wife Kristy Pitchford and Randy’s son Randy Jr.


Total votes 33: ↑32 and ↓1 +31
Comments 0

Support of Visual Studio 2019 in PVS-Studio

Reading time 19 min
Views 1K


Support of Visual Studio 2019 in PVS-Studio affected a number of components: the plugin itself, the command-line analyzer, the cores of the C++ and C# analyzers, and a few utilities. In this article, I will briefly explain what problems we encountered when implementing support of the IDE and how we addressed them.
Read more →
Total votes 31: ↑30 and ↓1 +29
Comments 0

Exceptional situations: part 1 of 4

Reading time 11 min
Views 2.1K


Introduction


It’s time to talk about exceptions or, rather, exceptional situations. Before we start, let’s look at the definition. What is an exceptional situation?


This is a situation that makes the execution of current or subsequent code incorrect. I mean different from how it was designed or intended. Such a situation compromises the integrity of an application or its part, e.g. an object. It brings the application into an extraordinary or exceptional state.


But why do we need to define this terminology? Because it will keep us in some boundaries. If we don’t follow the terminology, we can get too far from a designed concept which may result in many ambiguous situations. Let’s see some practical examples:


 struct Number
 {
     public static Number Parse(string source)
     {
         // ...
         if(!parsed)
         {
             throw new ParsingException();
         }
         // ...
     }

     public static bool TryParse(string source, out Number result)
     {
        // ..
        return parsed;
     }
 }

This example seems a little strange, and it is for a reason. I made this code slightly artificial to show the importance of problems appearing in it. First, let’s look at the Parse method. Why should it throw an exception?

Read more →
Total votes 27: ↑26 and ↓1 +25
Comments 2

Fancy Euclid's “Elements” in TeX

Reading time 7 min
Views 27K


In 2016, I came across Oliver Byrne's “The first six books of the Elements of Euclid.” The main feature of this book is that instead of ordinary letter designations such as “triangle ABC,” it employs inclusions of miniature pictures directly in the text, that is, for example, an image of a triangle. As difficult as it probably was in the XIX century, as easy, with the right tools, it should be to make such a book nowadays. And so I decided to find out by myself whether that's the case.
Read more →
Total votes 35: ↑34 and ↓1 +33
Comments 2