Python基于YOLOv8和OpenCV实现车道线和车辆检测
使用YOLOv8(You Only Look Once)和OpenCV实现车道线和车辆检测,目标是创建一个可以检测道路上的车道并识别车辆的系统,并估计它们与摄像头的距离。该项目结合了计算机视觉技术和深度学习物体检测。
1、系统主要功能
- 车道检测:使用边缘检测和霍夫线变换检测道路车道。
- 汽车检测:使用 YOLOv8 模型识别汽车并在汽车周围绘制边界框。
- 距离估计:使用边界框大小计算检测到的汽车与摄像头的距离。
2、环境要求
- OpenCV:用于图像处理和车道检测。
- Ultralytics YOLOv8:用于车辆检测。
- NumPy:用于数组操作。
pip install opencv-python-headless numpy ultralytics
opencv-python
和 opencv-python-headless
区别是 OpenCV 的 Python 包,主要区别在于是否包含 GUI 相关的功能。
opencv-python
- 包含 GUI 功能:支持窗口显示、鼠标事件等图形界面操作。
- 依赖:需要 GUI 库(如 GTK、Qt)支持。
- 适用场景:适用于需要显示图像或与用户交互的环境,如桌面应用。
opencv-python-headless
- 不包含 GUI 功能:去除了窗口显示和用户交互功能。
- 依赖:无需 GUI 库,适合无图形界面的环境。
- 适用场景:适用于服务器或无图形界面的环境,如远程服务器、Docker 容器。
选择建议
- 如果需要显示图像或与用户交互,选择
opencv-python
。 - 如果仅需图像处理且无图形界面需求,选择
opencv-python-headless
。
3、代码
import cv2
import numpy as np
import math
import time
from ultralytics import YOLO # YOLOv8 module# Function to mask out the region of interest
def region_of_interest(img, vertices):mask = np.zeros_like(img)match_mask_color = 255cv2.fillPoly(mask, vertices, match_mask_color)masked_image = cv2.bitwise_and(img, mask)return masked_image# Function to draw the filled polygon between the lane lines
def draw_lane_lines(img, left_line, right_line, color=[0, 255, 0], thickness=10):line_img = np.zeros_like(img)poly_pts = np.array([[(left_line[0], left_line[1]),(left_line[2], left_line[3]),(right_line[2], right_line[3]),(right_line[0], right_line[1])]], dtype=np.int32)# Fill the polygon between the linescv2.fillPoly(line_img, poly_pts, color)# Overlay the polygon onto the original imageimg = cv2.addWeighted(img, 0.8, line_img, 0.5, 0.0)return img# The lane detection pipeline
def pipeline(image):height = image.shape[0]width = image.shape[1]region_of_interest_vertices = [(0, height),(width / 2, height / 2),(width, height),]# Convert to grayscale and apply Canny edge detectiongray_image = cv2.cvtColor(image, cv2.COLOR_RGB2GRAY)cannyed_image = cv2.Canny(gray_image, 100, 200)# Mask out the region of interestcropped_image = region_of_interest(cannyed_image,np.array([region_of_interest_vertices], np.int32))# Perform Hough Line Transformation to detect lineslines = cv2.HoughLinesP(cropped_image,rho=6,theta=np.pi / 60,threshold=160,lines=np.array([]),minLineLength=40,maxLineGap=25)# Separating left and right lines based on slopeleft_line_x = []left_line_y = []right_line_x = []right_line_y = []if lines is None:return imagefor line in lines:for x1, y1, x2, y2 in line:slope = (y2 - y1) / (x2 - x1) if (x2 - x1) != 0 else 0if math.fabs(slope) < 0.5: # Ignore nearly horizontal linescontinueif slope <= 0: # Left laneleft_line_x.extend([x1, x2])left_line_y.extend([y1, y2])else: # Right laneright_line_x.extend([x1, x2])right_line_y.extend([y1, y2])# Fit a linear polynomial to the left and right linesmin_y = int(image.shape[0] * (3 / 5)) # Slightly below the middle of the imagemax_y = image.shape[0] # Bottom of the imageif left_line_x and left_line_y:poly_left = np.poly1d(np.polyfit(left_line_y, left_line_x, deg=1))left_x_start = int(poly_left(max_y))left_x_end = int(poly_left(min_y))else:left_x_start, left_x_end = 0, 0 # Defaults if no lines detectedif right_line_x and right_line_y:poly_right = np.poly1d(np.polyfit(right_line_y, right_line_x, deg=1))right_x_start = int(poly_right(max_y))right_x_end = int(poly_right(min_y))else:right_x_start, right_x_end = 0, 0 # Defaults if no lines detected# Create the filled polygon between the left and right lane lineslane_image = draw_lane_lines(image,[left_x_start, max_y, left_x_end, min_y],[right_x_start, max_y, right_x_end, min_y])return lane_image# Function to estimate distance based on bounding box size
def estimate_distance(bbox_width, bbox_height):# For simplicity, assume the distance is inversely proportional to the box size# This is a basic estimation, you may use camera calibration for more accuracyfocal_length = 1000 # Example focal length, modify based on camera setupknown_width = 2.0 # Approximate width of the car (in meters)distance = (known_width * focal_length) / bbox_width # Basic distance estimationreturn distance# Main function to read and process video with YOLOv8
def process_video():# Load the YOLOv8 modelmodel = YOLO('weights/yolov8n.pt')# 或者加载官方模型# model = YOLO("yolov8n.pt") # load an official model# Open the video filecap = cv2.VideoCapture('video/video.mp4')# Check if video opened successfullyif not cap.isOpened():print("Error: Unable to open video file.")return# Set the desired frame ratetarget_fps = 30frame_time = 1.0 / target_fps # Time per frame to maintain 30fps# Resize to 720p (1280x720)cap.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)cap.set(cv2.CAP_PROP_FRAME_HEIGHT, 720)# Loop through each framewhile cap.isOpened():ret, frame = cap.read()if not ret:break# Resize frame to 720presized_frame = cv2.resize(frame, (1280, 720))# Run the lane detection pipelinelane_frame = pipeline(resized_frame)# Run YOLOv8 to detect cars in the current frameresults = model(resized_frame)# Process the detections from YOLOv8for result in results:boxes = result.boxesfor box in boxes:x1, y1, x2, y2 = map(int, box.xyxy[0]) # Bounding box coordinatesconf = box.conf[0] # Confidence scorecls = int(box.cls[0]) # Class ID# Only draw bounding boxes for cars with confidence >= 0.5if model.names[cls] == 'car' and conf >= 0.5:label = f'{model.names[cls]} {conf:.2f}'# Draw the bounding boxcv2.rectangle(lane_frame, (x1, y1), (x2, y2), (0, 255, 255), 2)cv2.putText(lane_frame, label, (x1, y1 - 10),cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 255), 2)# Estimate the distance of the carbbox_width = x2 - x1bbox_height = y2 - y1distance = estimate_distance(bbox_width, bbox_height)# Display the estimated distancedistance_label = f'Distance: {distance:.2f}m'cv2.putText(lane_frame, distance_label, (x1, y2 + 20),cv2.FONT_HERSHEY_SIMPLEX, 0.5, (255, 0, 0), 2)# Display the resulting frame with both lane detection and car detectioncv2.imshow('Lane and Car Detection', lane_frame)# Limit the frame rate to 30fpstime.sleep(frame_time)# Break the loop when 'q' is pressedif cv2.waitKey(1) & 0xFF == ord('q'):break# Release video capture and close windowscap.release()cv2.destroyAllWindows()# Run the video processing function
process_video()
4、工作原理
4.1 车道线检测 Pipeline
车道线检测包括一下几个步骤:
Step 1: 屏蔽感兴趣区域(ROI)
只处理图像的下半部分(车道线通常是可见的)。
def region_of_interest(img, vertices):mask = np.zeros_like(img)match_mask_color = 255cv2.fillPoly(mask, vertices, match_mask_color)masked_image = cv2.bitwise_and(img, mask)return masked_image
Step 2: 使用Canny进行边缘检测
将图像转换为灰度,并应用Canny边缘检测来突出显示边缘。
gray_image = cv2.cvtColor(image, cv2.COLOR_RGB2GRAY)
cannyed_image = cv2.Canny(gray_image, 100, 200)
Step 3: 霍夫线变换
霍夫线变换用于检测当前车道的线段。
lines = cv2.HoughLinesP(cropped_image,rho=6,theta=np.pi / 60,threshold=160,lines=np.array([]),minLineLength=40,maxLineGap=25
)
4.2 使用YOLOv8进行车辆检测
Step 1: 加载YOLOv8模型
我们使用预训练的YOLOv8模型来检测每一帧中的汽车(或者使用官方提供的模型)。
from ultralytics import YOLO
model = YOLO('weights/yolov8n.pt')
# model = YOLO('yolov8n.pt') #官方提供的模型
Step 2: 绘制边界框
对于每一辆检测到的汽车,绘制边界框,并显示类名(汽车)和置信度分数。
for box in boxes:x1, y1, x2, y2 = map(int, box.xyxy[0])conf = box.conf[0]if model.names[cls] == 'car' and conf >= 0.5:label = f'{model.names[cls]} {conf:.2f}'cv2.rectangle(lane_frame, (x1, y1), (x2, y2), (0, 255, 255), 2)cv2.putText(lane_frame, label, (x1, y1 - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 255), 2)
Step 3:. 距离估计
根据边界框的大小估计到每辆检测到的汽车的距离。
def estimate_distance(bbox_width, bbox_height):focal_length = 1000 # Example focal lengthknown_width = 2.0 # Approximate width of a car (in meters)distance = (known_width * focal_length) / bbox_widthreturn distance
Step 4:. 视频处理 Pipeline
将车道检测、车辆检测和距离估计结合到一个实时视频处理pipeline中。
while cap.isOpened():ret, frame = cap.read()if not ret:breaklane_frame = pipeline(resized_frame)results = model(resized_frame)for result in results:# Draw bounding boxes and estimate distancecv2.imshow('Lane and Car Detection', lane_frame)if cv2.waitKey(1) & 0xFF == ord('q'):break
5、结果
- 项目源码地址:
https://github.com/CityIsBetter/Lane_Detection
相关文章:
![](https://i-blog.csdnimg.cn/direct/05815793712746dda4c578aab1a21a66.png#pic_center)
Python基于YOLOv8和OpenCV实现车道线和车辆检测
使用YOLOv8(You Only Look Once)和OpenCV实现车道线和车辆检测,目标是创建一个可以检测道路上的车道并识别车辆的系统,并估计它们与摄像头的距离。该项目结合了计算机视觉技术和深度学习物体检测。 1、系统主要功能 车道检测&am…...
![](https://www.ngui.cc/images/no-images.jpg)
代码随想录算法训练营第六十天|KM94.城市间货物运输Ⅰ|KM95.城市间货物运输Ⅱ|KM96.城市间货物运输Ⅲ
94. 城市间货物运输 I 2、Bellman_ford队列优化算法(又名SPFA) SPFA是对Bellman_ford算法的优化,由于Bellman_ford 算法 每次都是对所有边进行松弛,其实是多做了一些无用功。其实只需要对 上一次松弛的时候更新过的节点作为出发节…...
![](https://www.ngui.cc/images/no-images.jpg)
人工智能学习路线全链路解析
一、基础准备阶段(预计 2-3 个月) (一)数学知识巩固与深化 线性代数(约 1 个月): 矩阵基础:回顾矩阵的定义、表示方法、矩阵的基本运算(加法、减法、乘法)&…...
![](https://www.ngui.cc/images/no-images.jpg)
C++语言的学习路线
C语言的学习路线 C是一种强大的高级编程语言,广泛应用于系统软件、游戏开发、嵌入式系统和高性能应用等多个领域。由于其丰富的功能和灵活性,C是一门值得深入学习的语言。本文旨在为初学者制定一条系统的学习路线,帮助他们循序渐进地掌握C语…...
![](https://i-blog.csdnimg.cn/direct/a704b070dfad4f3fad0eaf504af4130a.png)
用于与多个数据库聊天的智能 SQL 代理问答和 RAG 系统(3) —— 基于 LangChain 框架的文档检索与问答功能以及RAG Tool的使用
介绍基于 LangChain 框架的文档检索与问答功能,目标是通过查询存储的向量数据库(VectorDB),为用户的问题检索相关内容,并生成自然语言的答案。以下是代码逻辑的详细解析: 代码结构与功能 初始化环境与加载…...
![](https://csdnimg.cn/release/blog_editor_html/release2.3.7/ckeditor/plugins/CsdnLink/icons/icon-default.png?t=O83A)
20250110doker学习记录
1.本机创建tts环境。用conda. 0.1安装。我都用的默认,你也可以。我安装过一次,如果修复,后面加 -u bash Anaconda3-2024.10-1-Linux-x86_64.sh等待一会。 (base) ktkt4028:~/Downloads$ conda -V conda 24.9.2学习资源 Conda 常用命令大…...
![](https://www.ngui.cc/images/no-images.jpg)
MPU6050: 卡尔曼滤波, 低通滤波
对于MPU6050(一种集成了三轴加速度计和三轴陀螺仪的惯性测量单元),对加速度值进行卡尔曼滤波,而对角速度进行低通滤波的选择是基于这两种传感器数据的不同特性和应用需求。以下是详细解释: 加速度值与卡尔曼滤波 为什么使用卡尔曼滤波? 噪声抑制: 加速度计信号通常包含…...
![](https://www.ngui.cc/images/no-images.jpg)
C++的标准和C++的编译版本
C的标准和C的编译版本:原理和概念 理解 C标准 和 C编译版本 的关系是学习 C 的一个重要部分。这两者虽然看似相关,但实际上分别涉及了不同的概念和技术。下面将通过层次清晰的解释,帮助新手理解这两个概念的差异、特点及其相互关系。 一、C标…...
![](https://i-blog.csdnimg.cn/direct/3d493da621ab458998514e061468daca.png)
python学习笔记—17—数据容器之字符串
1. 字符串 (1) 字符串能通过下标索引来获取其中的元素 (2) 旧字符串无法修改特定下标的元素 (3) index——查找字符串中任意元素在整个字符串中的起始位置(单个字符或字符串都可以) tmp_str "supercarrydoinb" tmp_position1 tmp_str.index("s") tmp_p…...
![](https://i-blog.csdnimg.cn/direct/65b16edc63464552a6c7e36ec1f7586f.png#pic_center)
UE5 使用内置组件进行网格切割
UE引擎非常强大,直接内置了网格切割功能并封装为蓝图节点,这项功能在UE4中就存在,并且无需使用Chaos等模块。那么就来学习下如何使用内置组件实现网格切割。 1.配置测试用StaticMesh 对于被切割的模型,需要配置一些参数。以UE5…...
![](https://i-blog.csdnimg.cn/direct/47b8739c21a64a5693c12a3a2452334c.png)
51单片机——串口通信(重点)
1、通信 通信的方式可以分为多种,按照数据传送方式可分为串行通信和并行通信; 按照通信的数据同步方式,可分为异步通信和同步通信; 按照数据的传输方向又可分为单工、半双工和全双工通信 1.1 通信速率 衡量通信性能的一个非常…...
![](https://i-blog.csdnimg.cn/direct/2225de68cae34e8b9c57f62fd67cf8d3.gif#pic_center)
Taro+Vue实现图片裁剪组件
cropper-image-taro-vue3 组件库 介绍 cropper-image-taro-vue3 是一个基于 Vue 3 和 Taro 开发的裁剪工具组件,支持图片裁剪、裁剪框拖动、缩放和输出裁剪后的图片。该组件适用于 Vue 3 和 Taro 环境,可以在网页、小程序等平台中使用。 源码 https:…...
![](https://i-blog.csdnimg.cn/direct/7ce845f9d1094f2891ba4d6181ba5005.png)
PHP民宿酒店预订系统小程序源码
🏡民宿酒店预订系统 基于ThinkPHPuniappuView框架精心构建的多门店民宿酒店预订管理系统,能够迅速为您搭建起专属的、功能全面且操作便捷的民宿酒店预订小程序。 该系统不仅涵盖了预订、退房、WIFI连接、用户反馈、周边信息展示等核心功能,更…...
![](https://i-blog.csdnimg.cn/direct/1bdd02513a4c46edafeed1056e3eb2b3.png)
Hadoop3.x 万字解析,从入门到剖析源码
💖 欢迎来到我的博客! 非常高兴能在这里与您相遇。在这里,您不仅能获得有趣的技术分享,还能感受到轻松愉快的氛围。无论您是编程新手,还是资深开发者,都能在这里找到属于您的知识宝藏,学习和成长…...
![](https://www.ngui.cc/images/no-images.jpg)
VUE3 常用的组件介绍
Vue 组件简介 Vue 组件是构建 Vue 应用程序的核心部分,组件帮助我们将 UI 分解为独立的、可复用的块,每个组件都有自己的状态和行为。Vue 组件通常由模板、脚本和样式组成。组件的脚本部分包含了各种配置选项,用于定义组件的逻辑和功能。 组…...
![](https://www.ngui.cc/images/no-images.jpg)
deepin-Wine 运行器合并打包器和添加从镜像提取 DLL 的功能
Wine 运行器是一个图形化工具,旨在简化 Wine 环境的管理和使用。它不仅提供了运行和管理 Wine 容器的功能,还增加了打包器和从镜像提取 DLL 的功能。以下是该工具的详细介绍和使用方法。 一、工具概述 Wine 运行器是一个使用 Python3 的 tkinter 构建的图…...
![](https://www.ngui.cc/images/no-images.jpg)
[大模型]本地离线运行openwebui+ollama容器化部署
本地离线运行Openweb-ui ollama容器化部署 说明安装internet操作内网操作问题线程启动错误最终命令总结说明 最近公司有一个在内网部署一个离线大模型的需求,网络是离线状态,服务器有A100GPU,一开始是想折腾开源chatGML4大模型,因为使用过gml3,所以想着部署gml4应该不难。…...
![](https://i-blog.csdnimg.cn/direct/48db69ec3d6b4ed3a421d4b9384151c5.png)
再次梳理ISP的大致流程
前言: 随着智能手机的普及,相机与我们的生活越来越紧密相关。在日常生活中,我们只需要轻轻按下手机上的拍照按钮,就能记录下美好时刻。那么问题来了:从我们指尖按下拍照按钮到一张色彩丰富的照片呈现在我们面前&#x…...
![](https://i-blog.csdnimg.cn/direct/4b361f886d6847ff9ec173bd76c64917.png)
HBuilderX打包ios保姆式教程
1、登录苹果开发者后台并登录已认证开发者账号ID Sign In - Apple 2、创建标识符(App ID)、证书,描述文件 3、首先创建标识符,用于新建App应用 3-1、App的话直接选择第一个App IDs,点击右上角继续 3-2、选择App&#x…...
![](https://www.ngui.cc/images/no-images.jpg)
《解锁鸿蒙系统AI能力,开启智能应用开发新时代》
在当今科技飞速发展的时代,鸿蒙系统以其独特的分布式架构和强大的AI能力,为开发者们带来了前所未有的机遇。本文将深入探讨开发者如何利用鸿蒙系统的AI能力开发更智能的应用,开启智能应用开发的新时代。 鸿蒙系统构筑了15系统级的AI能力&…...
![](https://i-blog.csdnimg.cn/direct/604370216fb04cff8f76e070b89aebf9.jpeg)
rhcsa练习(3)
1 、创建文件命令练习: ( 1 ) 在 / 目录下创建一个临时目录 test ; mkdir /test ( 2 )在临时目录 test 下创建五个文件,文件名分别为 passwd , group , bashrc &#x…...
![](https://i-blog.csdnimg.cn/direct/3c19f50684d440f0bca76d073fcf2fd3.png)
科研绘图系列:R语言绘制Y轴截断分组柱状图(y-axis break bar plot)
禁止商业或二改转载,仅供自学使用,侵权必究,如需截取部分内容请后台联系作者! 文章目录 介绍特点意义加载R包数据下载导入数据数据预处理画图输出总结系统信息介绍 Y轴截断分组柱状图是一种特殊的柱状图,其特点是Y轴的刻度被截断,即在某个范围内省略了部分刻度。这种图表…...
![](https://www.ngui.cc/images/no-images.jpg)
跳出技术陷阱,探索财富自由的多元路径
自古以来,我们常听到这样一句话:“一技在手,吃穿不愁”。这种理念在以往的时代背景下,确实为许多人提供了稳定的生计保障。然而,在信息爆炸、产能过剩的今天,这种固守一技之长的观念正逐渐显露出其不足&…...
![](https://i-blog.csdnimg.cn/blog_migrate/45f5aa2e88f147453c0764b3e7543f63.jpeg)
qml SpringAnimation详解
1. 概述 SpringAnimation 是 Qt Quick 中用于模拟弹簧效果的动画类。它通过模拟物体在弹簧力作用下的反应,产生一种振荡的动画效果,常用于模拟具有自然回弹、弹性和振动的动态行为。这种动画效果在 UI 中广泛应用,特别是在拖动、拉伸、回弹等…...
![](https://i-blog.csdnimg.cn/direct/b5fea6b0fd9c470381685bfa7e1fa1ec.png)
中学综合素质笔记3
第一章职业理念 第三节 教师观 考情提示: 单选题材料分析题 学习要求: 理解、 识记、 运用 (一)教师职业角色的转变(单选材料分析) 从教师与学生的关系看——对学生 新课程要求教师应该是学生学习的引…...
![](https://i-blog.csdnimg.cn/direct/df2999cc3b88489596df5ca33f4f3d84.png)
uniapp vue2版本如何设置i18n
如何设置i18n在该软件设置过语言的情况下优先选择所设置语言,在没有设置的情况下,获取本系统默认语言就,将系统默认语言设置为当前选择语言。 1、下载依赖: npm install vue-i18n --save 2、创建相关文件(在最外层&…...
![](https://i-blog.csdnimg.cn/direct/4e264024682c48c9a6d0f42585d50ccb.png)
【踩坑记录❌】ubuntu 安装 NVIDIA 显卡驱动不要 autoinstall
背景 在 ubuntu 22.04 安装 NVIDIA 显卡驱动参考了 博客 的步骤进行,发现有很多评论也出现了无法联网的情况 后续解决 尝试了网卡驱动下载的各类方法,安装驱动的过程中又缺失内核头、 gcc 编译器等文件。由于没有网络,每次缺失的文件只能从…...
![](https://i-blog.csdnimg.cn/direct/ff9de181b3df46179b1d7e02291e32af.png)
vue3 + ts + element-plus(el-upload + vuedraggable实现上传OSS并排序)
这里创建项目就不多说了 安装element-plus npm install element-plus 安装vuedraggable npm install vuedraggable 安装ali-oss npm install ali-oss 这里是封装一下:在components创建文件夹jc-upload>jc-upload.vue 在封装的过程中遇到了一个问题就是dr…...
![](https://www.ngui.cc/images/no-images.jpg)
SQL开窗函数相关的面试题和答案
基本排序与分组问题 题目:有学生成绩表tb_score,包含字段SNO(学号)、SCLASS(班级)、CHINESE(语文成绩)、ENGLISH(英语成绩)、ARITH(数学成绩&…...
![](https://www.ngui.cc/images/no-images.jpg)
【数据分析(一)】初探 Numpy
目录 前言1. 一维 array 的生成2. 一维 array 的基本操作2.1. 查看属性2.2. 花式索引2.3. 条件筛查2.4. 数据统计 3. n 维 array 的生成4. n 维 array 的基本操作4.1. 查看属性4.2. 查询和切片4.3. 花式索引4.4. 矩阵 前言 Numpy是Python的常用开源数值计算扩展库,用…...
![](/images/no-images.jpg)
自己能开发app软件吗/seo和sem的关系
按照此文档 最简单的eclipse安装方法 sudo apt-get install eclipse 弊端:因为ubuntu默认安装的不是最新版本的eclipse,所以你也不能安装最新的pydev。 两个都安装成功 2016/11/10 现已删除eclipse 安装新的eclipse:参考文献 转载于:https://www.cnblogs.com/amelie…...
![](/images/no-images.jpg)
wordpress 描述/自动点击器下载
DataList是ASP.NET的数据控件之一,在使用时要对其进行数据绑定。但是使用过程中难免会出现需要根据已绑定表中的某列数据来作进一步的查询和显示,就需要使用DataList嵌套来解决此类问题。 举例: 1.要显示一张公司的组织结构表,要显…...
![](/images/no-images.jpg)
建国汽车网址大全/苏州seo快速优化
-----Java培训、Android培训、iOS培训、.Net培训、期待与您交流!----- 一、protocol简单使用 1>基本用途 1.可用来声明方法。 2.只要某个类遵守了这个协议,就相当于拥有这个协议中的所有方法声明。 3.只要父类遵守了这个协议,就相当于子类…...
![](/images/no-images.jpg)
龙湖什么网站做宣传/外贸平台自建站
**章 简介Web应用程序的历史对servlet的支持servlet的优势第二章 HTTP Servlet基础HTTP基础Servlet API制作网页Web应用程序总结第三章 servlet的生命周期servlet的选择servlet重新载入init和destroy单线程模式后台处理启动时载入客户端缓存服务端缓存第四章 获取信息Servl…...
![](/images/no-images.jpg)
天津网站建设普斯泰/百度查重
Flutter 在 Build完成后的监听和每一帧绘制完成后的监听 这个是我们监听要用的重要的类------->WidgetsBinding 官方是这么描述它的 The glue between the widgets layer and the Flutter engine. 中文的意思是 控件层和Flutter引擎之间的粘合剂。就是这个类 它能监听到…...
![](https://img-blog.csdnimg.cn/0532741d6fa147bea4d11c965f554e05.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBAc3RvbmVfdGlnZXJMSQ==,size_19,color_FFFFFF,t_70,g_se,x_16)
公司网站备案 问我借身份证 怎么拒绝/seo优化技术培训
1、安装N卡驱动 首先添加源 sudo add-apt-repository ppa:graphics-drivers/ppa sudo apt update然后检查可以安装的驱动版本号 nvidia-msi选择适合自己的驱动,这里需要注意不同版本的cuda需要的驱动版本号也不一样,参考表链接点这里 Ubuntu 18.04安…...