Skip to content

MichaelAkridge-NOAA/Fish-or-No-Fish-Detector

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

31 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

makerlab opensci

Fish or No Fish Detector

Is there a fish 🐟 or not?

GIF description

Features:

  • Upload one or more images to detect Fish
  • Adjust the confidence threshold for predictions & output
  • Download all detection results, counts and bounding box results in JSON format

Example of Fish Detection:

Example of No Fish Detection:

Example of Result Data:

JSON Result Output

    {
        "image_name": "03.jpg",
        "bounding_boxes": [
            {
                "x1": 19.213233947753906,
                "y1": 83.37771606445312,
                "x2": 708.1510620117188,
                "y2": 422.69561767578125,
                "confidence": 0.9245972037315369,
                "class_id": 2,
                "class_label": "Fish"
            }
        ],
        "fish_count": 1,
        "confidences": [
            0.9245972037315369
        ]
    },

Installation

  1. Clone the repository:
    git clone https://github.com/MichaelAkridge-NOAA/Fish-or-No-Fish-Detector.git
    cd Fish-or-No-Fish-Detector
    
  2. Install the required dependencies:
    pip install -r requirements.txt
    
  3. Download one of the pre-trained models and save it in the ./models/ directory.

Running the App

Run the Streamlit app with the following command:

streamlit run app.py

Fish or No Fish - Video

Track & Plot Fish Over Time

GIF description

Read More/How to:

Model Links:

Model Details

Model trained to detect fish in underwater Grayscale Imagery using the YOLOv8n architecture for performance. The model leverages unsupervised learning techniques to learn patterns and identify fish without relying on fully labeled datasets.Uses the FathomNet VME Model for object detection in marine ecosystems, specifically focusing on corals, crinoids, sponges, and fish in its unsupervised learning method. It is built on top of the Ultralytics YOLOv8x model, providing fast and accurate object detection capabilities.


Disclaimer

This repository is a scientific product and is not official communication of the National Oceanic and Atmospheric Administration, or the United States Department of Commerce. All NOAA GitHub project content is provided on an β€˜as is’ basis and the user assumes responsibility for its use. Any claims against the Department of Commerce or Department of Commerce bureaus stemming from the use of this GitHub project will be governed by all applicable Federal law. Any reference to specific commercial products, processes, or services by service mark, trademark, manufacturer, or otherwise, does not constitute or imply their endorsement, recommendation or favoring by the Department of Commerce. The Department of Commerce seal and logo, or the seal and logo of a DOC bureau, shall not be used in any manner to imply endorsement of any commercial product or activity by DOC or the United States Government.

License

See the LICENSE.md for details on this code.

Credits
  • MakerLab team at PIFSC, who generously contributed ideas, test data, and AI development techniques & direction. Their collaboration and innovative ideas have been invaluable in shaping the detection techniques used in this project and advancing marine ecosystem research.
  • Fathomnet for base trained model layer used for semi-unsupervised training of new detection model
makerlab opensci fathomnet