09.06.2021

Artificial intelligence to help animals


Over the last few years we have been witnessing a tremendous development in the design and use of AI-based algorithms that are being applied in numerous domains of human life. One of these domains is veterinary medicine. As animals struggle with cancer as well as with a wide variety of inflammatory conditions, it is these ailments and illnesses that have become the main area of interest for researchers involved in the CyfroVet Project – a new generation of smart tools for veterinary diagnostics, delivered by the CYFRONET AGH Academic Computer Centre. The project is being carried out by a team of veterinary experts working together with scientists specialising in artificial intelligence.

The main aim of the CyfroVet Project is to reduce the amount of time taken by cytology examination, which is currently the first step in diagnosing cancerous lesions in animals. Today, the time required to obtain results of a cytology test is between a few days and two weeks, with the cost of such a test amounting to a few hundred Polish zloty. One should also take into account additional expenses incurred when sending samples to diagnostic laboratories.

Using a newly developed, automated system it will be possible to significantly reduce the waiting time for preliminary results. It will enable diagnosticians to take photographs of cytology samples and then analyse them with the use of AI algorithms, which allow for quick assessment of pathological lesions found in the samples. Based on these findings, doctors will find it easier to take preliminary decisions regarding further steps in diagnostics and treatment.

 

 

Fig. 1. CyfroVet diagnostics – block diagram

The design and implementation of such a system comes with numerous challenges. The first (and formidable) one is to collect sufficient number of photographs of cytology samples displaying various characteristics, which will allow the AI-based algorithm to get properly trained in recognising cancerous lesions.

A cytology sample seen as a macroscale photograph is highly heterogeneous. The photograph shows areas of higher and lower diagnostic potential. A specialist doctor can pre-identify them and undertake their closer analysis to diagnose the condition. A system for cytology diagnostics should also address this stage of sample analysis. Only the properly selected fragments of the image revealing relevant pathological lesions will enable highly accurate diagnosis.

The process of labelling training data, for which lesions must be manually labelled by an expert doctor and verified by a certified pathologist, also requires a lot of time. This stage, however, is necessary if one wants to ensure that the system based on AI keeps working properly.

The personnel involved in the CyfroVet project has already devised a solution which enables classification of selected pathological lesions using neural networks. Network architectures have also been developed, enabling detailed detection and semantic segmentation of individual cancerous cells, which will allow a more thorough analysis of pathological changes that are taking place.

 

 

Fig. 2. Cancer types included in the data set

Fig. 3. Data and model preparation process

The solution designed by the CyfroVet team offers classification accuracy rate of as much as 96%. The system works for three selected cancerous lesions: mastocytoma, histiocytoma and lymphoma (Fig. 2). The model, which uses detection based on the YOLOv3 algorithm, enables working teams to isolate within the image of the cytology samples the so-called fields of interest. The process of creating the model has been presented in Fig. 3. Another model, based on semantic segmentation, is currently under development. It is characterised by more accurate results so that areas of pathological changes can be isolated with the accuracy rate of up to one pixel.

Recently, the team has been conducting research into a more holistic approach to veterinary diagnostics, which would encompass both microscopic examination of lesions revealed on the photographs of cytology samples as well as information about the animal ‘patient’ obtained by the veterinary doctor during an initial interview. Such an interview should include the assessment of the ‘patient’s’ condition based on the animal’s age, its medical history, location of lesions on the skin as well as other data that can be obtained from the animal’s owner. These are the so called categorical data, which may have a substantial impact on diagnostic decisions to be taken by the vet. Incorporating such data into the AI algorithm will boost its efficiency and allow generalisation of its results (Fig. 4). In machine learning, this process is known as the use of multiple modalities for building models.

 

 

Fig. 4. Diagnostic process incorporating categorical information collected by a vet.

The Project is being implemented at the Laboratory for Computational Acceleration and Artificial Intelligence, which is part of the CYFRONET AGH Academic Computer Centre, by:

  • Jakub Caputa, Daria Łukasik – ACK Cyfronet AGH,
  • professor Kazimierz Wiatr, professor Paweł Russek, Maciej Wielgosz, DsC, Rafał Frączek, DsC, Michał Karwatowski, MsC – ACK Cyfronet AGH, Faculty of Computer Science, Electronics and Telecommunications.