search
HomeTechnology peripheralsAIArtificial intelligence yolov7 target detection is deployed on ubuntu

Today we introduce the deployment of object recognition yolov7 deployment on Ubuntu

1. A brief introduction to Anaconda

First of all, you need to download Anaconda to create a virtual environment, which is currently the most convenient

Creating a virtual environment does not affect other environments of the machine

1. Virtual environment management

1.1conda ‐version            # Get the conda version

1.2 conda update conda #Upgrade conda

1.3conda env list (list virtual environment information)

<code>conda create -n <env_name> (创建虚拟环境)# 命令示例conda create -n py38 -yconda create -n py39 python=3.9 -y# 官方推荐使用这种方式conda create -n py39_2 -y && conda install -n py39_2 python=3.9 -y</env_name></code>

Specify the python version when creating the environment, and The results of installing the specified version of python after creating the environment are no different. So why does the official recommend using python=3.9 to specify the python

version when creating the environment? This is because if you want to use python in this virtual environment, you should download python3.9 at the beginning of creating the environment. Then other packages downloaded in this virtual environment will match the dependencies and constraints of python3.9. If you install python3.9 after installing many other packages, dealing with environmental dependencies will become more complicated, and may even lead to some subtle bugs

1.4conda activate (Enter the virtual environment)

# Command example

conda activate py39

1.5conda deactivate (Exit the virtual environment)

# Command example

conda deactivate

1.6conda remove -n --all Delete virtual environment

# Delete test virtual environment

conda remove -n test --all

conda env list

2. Channels management

2.1 List the channels configured in conda, according to the priority from low to high Level arrangement

conda config --get channels

2.2 Add channels, add domestic channels, which is what we often call adding domestic sources

<code>conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/conda-forge/conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda/</code>

2.3 Delete channels

<code>方法 1 (通过命令删除):# 首先查看 channelsconda config --get channels# 删除指定的 channelsconda config --remove channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/bioconda/方法 2 (编辑 .condarc 文件删除想要删除 channels 对应的行)vi ~/.condarc</code>

2. Yolov7 deployment

1. conda create -n py python=3.8

Created successfully, enter the virtual environment

conda activate py

2. Download yolov7

You can rewrite this sentence as: "Use the following command to clone WongKinYiu YOLOv7 code base: git clone https://github.com/WongKinYiu/yolov7.git”

Directly download the compressed package https://github.com/WongKinYiu/yolov7.git

After the download is completed, enter the folder

cd yolov7

Install dependencies

pip install -r requirements.txt

Patiently wait for the dependency package to be installed successfully

3. Download the model file

Artificial intelligence yolov7 target detection is deployed on ubuntu

<code>https://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7.pthttps://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7x.pthttps://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7-w6.pthttps://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7-e6.pthttps://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7-d6.pthttps://github.com/WongKinYiu/yolov7/releases/download/v0.1/yolov7-e6e.pt</code>

and then run

python detect.py --weights yolov7.pt -- conf 0.25 --img-size 640 --source inference/images/horses.jpg

Artificial intelligence yolov7 target detection is deployed on ubuntu

See if there are other modules missing, just download them with pip separately

The above is the detailed content of Artificial intelligence yolov7 target detection is deployed on ubuntu. For more information, please follow other related articles on the PHP Chinese website!

Statement
This article is reproduced at:51CTO.COM. If there is any infringement, please contact admin@php.cn delete
A Comprehensive Guide to ExtrapolationA Comprehensive Guide to ExtrapolationApr 15, 2025 am 11:38 AM

Introduction Suppose there is a farmer who daily observes the progress of crops in several weeks. He looks at the growth rates and begins to ponder about how much more taller his plants could grow in another few weeks. From th

The Rise Of Soft AI And What It Means For Businesses TodayThe Rise Of Soft AI And What It Means For Businesses TodayApr 15, 2025 am 11:36 AM

Soft AI — defined as AI systems designed to perform specific, narrow tasks using approximate reasoning, pattern recognition, and flexible decision-making — seeks to mimic human-like thinking by embracing ambiguity. But what does this mean for busine

Evolving Security Frameworks For The AI FrontierEvolving Security Frameworks For The AI FrontierApr 15, 2025 am 11:34 AM

The answer is clear—just as cloud computing required a shift toward cloud-native security tools, AI demands a new breed of security solutions designed specifically for AI's unique needs. The Rise of Cloud Computing and Security Lessons Learned In th

3 Ways Generative AI Amplifies Entrepreneurs: Beware Of Averages!3 Ways Generative AI Amplifies Entrepreneurs: Beware Of Averages!Apr 15, 2025 am 11:33 AM

Entrepreneurs and using AI and Generative AI to make their businesses better. At the same time, it is important to remember generative AI, like all technologies, is an amplifier – making the good great and the mediocre, worse. A rigorous 2024 study o

New Short Course on Embedding Models by Andrew NgNew Short Course on Embedding Models by Andrew NgApr 15, 2025 am 11:32 AM

Unlock the Power of Embedding Models: A Deep Dive into Andrew Ng's New Course Imagine a future where machines understand and respond to your questions with perfect accuracy. This isn't science fiction; thanks to advancements in AI, it's becoming a r

Is Hallucination in Large Language Models (LLMs) Inevitable?Is Hallucination in Large Language Models (LLMs) Inevitable?Apr 15, 2025 am 11:31 AM

Large Language Models (LLMs) and the Inevitable Problem of Hallucinations You've likely used AI models like ChatGPT, Claude, and Gemini. These are all examples of Large Language Models (LLMs), powerful AI systems trained on massive text datasets to

The 60% Problem — How AI Search Is Draining Your TrafficThe 60% Problem — How AI Search Is Draining Your TrafficApr 15, 2025 am 11:28 AM

Recent research has shown that AI Overviews can cause a whopping 15-64% decline in organic traffic, based on industry and search type. This radical change is causing marketers to reconsider their whole strategy regarding digital visibility. The New

MIT Media Lab To Put Human Flourishing At The Heart Of AI R&DMIT Media Lab To Put Human Flourishing At The Heart Of AI R&DApr 15, 2025 am 11:26 AM

A recent report from Elon University’s Imagining The Digital Future Center surveyed nearly 300 global technology experts. The resulting report, ‘Being Human in 2035’, concluded that most are concerned that the deepening adoption of AI systems over t

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Chat Commands and How to Use Them
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.