AI headshot generator built with generative AI

  • Category:
  • Artificial Intelligence Services

A gathering data, synthetic dataset, model validation, and implementation case study

The client

Our client, a top-tier startup, runs an online service that focuses on transforming home-taken photographs into a format required in official documents. By using the company’s services, one can take a selfie with a mobile phone and, after a bit of tuning done by the client’s software, it can be used in an ID, a driver’s license, or a passport. 

 The company operates in multiple countries, supporting various types of documents and image formats. The core of the company’s operations is founded on using AI-based image processing solutions. In order to meet the document guidelines, the image needs to be:

  • Icon check

    Properly angled

  • Icon check

    Cleansed of a real-life background, leaving only a solid one

  • Icon check

    Resized, either reduced or improved with quality

  • Icon check

    Compliant with lighting and brightness standards

While Tooploox supports the client with all the challenges mentioned above, this case study focuses solely on the latter.

The challenge

When it comes to building an AI-based solution, one of the key challenges is to gather the data that the algorithm will be trained and validated on. The task is relatively easy when it comes to gathering images that are widespread on the internet. However, building a solution to modify lighting levels was something completely different. 

The main challenge was to build the dataset to train the algorithm from scratch. 

To tackle the problem, the Tooploox team and the client’s engineers delivered two independent ways to build a dataset from scratch: 

  • Icon check

    A fully automated photo setup with multiple lights and cameras 

  • Icon check

    An AI-based artificial data production pipeline

Collecting a dataset to build and test the algorithms to validate and correct the lighting in the photos was one of the biggest challenges during development. The perfect data for this project would consist of an image of the same person sitting in the same pose while being photographed with various shades and disturbances in terms of face lighting levels. Also, an image of the same person with perfect lighting would be required as the desired effect provided for the machine.

Our solution

Although it would be possible to gather data regarding various levels of lighting, it would be shown to different people – something that is impossible for a machine to overcome.

Thus, as mentioned above, the teams have built two solutions – an IoT-based solution and an AI professional headshot generator.

  • Icon check

    Supporting Data Collection

    The most intuitive way to tackle this problem was to actually make a set of photos of the same person with different lighting conditions. To make the process efficient, the session had to be as short as possible while collecting as many photos as possible. 

    To tackle this challenge, Tooploox and client’s engineers worked together to deliver a red carpet photos-like device with multiple digital cameras and even more photo lamps to provide cameras with different lighting conditions, from severe under-lighting to maximum over-exposure and everything in between, including various levels of lighting and multiple types of shades on the face. In the end, the user feels like a celebrity with dozens of flashing lights and photos taken in a very short amount of time. 

    To make the process as automated, swift, and efficient as possible, the whole system is controlled by the Arduino system, so the full set of images can be taken with a single click. The model needs to sit still for just four minutes, and the process is over, providing the team with a set of images necessary to train and validate the model. All the work was delivered in close cooperation with the client’s engineering team to ensure the highest quality of the final product.

    Arduino is an open-source hardware and software platform that enables engineers to easily build prototypes and automated systems controlled by a central computer minimized to the size of a large playing cards deck. Arduino is widely used by engineers around the world to test ideas, build automated smart-home systems, control industrial and semi-industrial installations and much more.

    The data created in this way is top-class and more than sufficient. But when it comes to building AI-based solutions, there is nothing like “having too much data.” Considering this, the Tooploox team came up with another solution. 

  • Icon check

    Artificial Data Generation using Generative AI

    For modern artificial intelligence-based solutions, generating faces of unreal people is not a challenge at all – there is even a website with a meaningful domain:

    The whole idea of a Generative Adversarial Network (GAN) is based on two neural networks – the first one, called the generator, is taught to generate fake data and the second one, called the discriminator, is trained in spotting the differences between the fake and the real. The technique appears to have delivered marvelous results in image recognition and image processing tasks. 

    But in addition, a neural network using GAN can generate a convincing (if not lifelike) image that can be further used – for example, to produce artificial images of people that were then put through a set of filters to emulate various levels of lighting and exposition. This approach enabled us to produce literally thousands of AI-generated headshots of different people with a variety of lighting conditions for an extremely low cost. 

    In the end, the Tooploox team, in cooperation with client’s engineering team, delivered a full pipeline for the production of the artificial data used to train the algorithm. When combined with the Arduino-controlled photobooth to gather real-life data, the company was provided with a complete and comprehensive pipeline of training and validation data. 

    With the experience and knowledge of  the client’s engineering team, the company was now able to fully harness the power of the Artificial Intelligence solutions and the best AI headshot generator to further expand the image database. 

The Effect

Now provided with proper data produced by the headshot AI generator, our client is able to build and implement algorithms that transform images with various lighting conditions into document-ready photos. 

Client is securing its position as a leader on the market, enabling users to have a document-ready photo done without going out – a significant advantage in the pandemic world. Photographs are then shipped to the person in need for future use, so whether the physical or digital copy is required, the client comes in to help. This would be impossible without a database of AI-generated professional headshots!

Decore Serpent

Let our specialists solve the problems and tackle the challenges that hold you from conquering the world.

Let’s talk