How AI Helps Track and Save Endangered Species

Manav AdwaniManav Adwani
3 min read

Introduction

As endangered species face the threat of extinction, it has become crucial to monitor and track their populations. To achieve this, researchers have deployed camera traps and satellites to analyze their movements and capture images. However, with vast datasets of wildlife images, manually identifying and classifying each species is extremely time-consuming and overwhelming for humans. This labor-intensive process complicates management and tracking efforts, often leading to errors.

To reduce manual intervention, advanced AI-driven image recognition models can automate this process, ensuring timely and accurate monitoring while supporting conservation efforts

CNN : Convolutional Neural Network

Convolutional Neural Network is type of Deep Learning model which works on four pillars which are image recognization , image normalisation, object detection and classification. CNN reduces the manual intervention and makes the classification error prone.

CNN consists of multiple layers , each serving a different purpose and helps to extract the features of the image.

  1. Convolutional Layers: These layers pull out key details from images. Filters scan the pictures to spot patterns like edges, shapes, and textures. As the network goes deeper, the filters learn more complex features, like specific textures or whole object shapes.

  2. Activation Function (ReLU) : ReLU is used to introduce non-linearity by replacing the negative value with zero. It helps the CNN model with complex patterns.

  3. Pooling Layers: These layers shrink the size of the data (width and height) while keeping key features. This process, called down-sampling, cuts down on computer work and helps prevent overfitting by focusing on the strongest features.

  4. Fully Connected Layers (Dense Layers): These layers come after feature extraction. They combine the high-level features learned earlier and do the final sorting.

Learning Through Implementation: CNN in Wildlife Classification

For better understanding of the Artificial Intelligence models , I have implemented this in my own project which uses CNN for classification.

Data Augmentation :

transform = transforms.Compose([
    transforms.RandomResizedCrop(224),
    transforms.RandomHorizontalFlip(),
    transforms.ColorJitter(),
    transforms.ToTensor(),
    transforms.Normalize(mean, std)
])

CNN Model Design

self.cnn = nn.Sequential(
    nn.Conv2d(3, 64, 3, padding=1),
    nn.BatchNorm2d(64),
    nn.ReLU(),
    nn.MaxPool2d(2, 2),

    nn.Conv2d(64, 128, 3, padding=1),
    nn.BatchNorm2d(128),
    nn.ReLU(),
    nn.MaxPool2d(2, 2),

    nn.Conv2d(128, 256, 3, padding=1),
    nn.BatchNorm2d(256),
    nn.ReLU(),
    nn.MaxPool2d(2, 2),

    nn.AdaptiveAvgPool2d((1, 1))
)

Key Formula

Convolution Output Size

$$\text{Output} = \frac{(W - K + 2P)}{S} + 1$$

$$\begin{align*} \text{Where:} \\W & = \text{Input width (original size of the input feature map)} \\K & = \text{Kernel size (dimension of the filter)} \\P & = \text{Padding (number of pixels added to each side)} \\S & = \text{Stride (number of pixels the filter moves at each step)} \end{align*}$$

Training the Model

To train the model, I used:

  • CrossEntropyLoss: for multi-class classification

  • Adam Optimizer: for efficient gradient updates

  • GPU Acceleration: using an RTX GPU for faster training

for images, labels in train_loader:
    optimizer.zero_grad()
    outputs = model(images)
    loss = criterion(outputs, labels)
    loss.backward()
    optimizer.step()

Conclusion

AI is transforming the way we monitor and conserve endangered species, particularly with regard to deep learning models like CNNs. AI decreases human effort while increasing accuracy, from identifying animals in deep forests to instantly evaluating thousands of camera trap images. In the future, as technology develops, intelligent technologies will help conservationists make quicker, more informed judgments that have the potential to save lives.

I now have a better understanding of convolutional neural networks' operation and their potential applications outside of the realm of technology, particularly in the context of wildlife protection. Although it's only a little step, it opens the way to creating more ethical, sustainable, and intelligent solutions for our planet.

To see the working of my website visit : Species-Recognition

0
Subscribe to my newsletter

Read articles from Manav Adwani directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Manav Adwani
Manav Adwani