Pyqt QCustomPlot 简介、安装与实用代码示例(三)

目录

  • 前言
  • 实用代码示例
    • Line Style Demo
    • Date Axis Demo
    • Parametric Curves Demo
    • Bar Chart Demo
    • Statistical Box Demo

所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 nixgnauhcuy’s blog!

如需转载,请标明出处!

完整代码我已经上传到 Github 上了,可前往 https://github.com/nixgnauhcuy/QCustomPlot_Pyqt_Study 获取。
完整文章路径:

  • Pyqt QCustomPlot 简介、安装与实用代码示例(一) | nixgnauhcuy
  • Pyqt QCustomPlot 简介、安装与实用代码示例(二) | nixgnauhcuy
  • Pyqt QCustomPlot 简介、安装与实用代码示例(三) | nixgnauhcuy
  • Pyqt QCustomPlot 简介、安装与实用代码示例(四) | nixgnauhcuy

前言

继上文,继续补充官方示例 demo 实现~

实用代码示例

Line Style Demo

A demonstration of several line styles

import sys, math

from PyQt5.QtWidgets import QApplication, QGridLayout, QWidget
from PyQt5.QtGui import QPen, QColor, QFont
from QCustomPlot_PyQt5 import QCustomPlot, QCPGraph, QCPScatterStyle

class MainForm(QWidget):

    def __init__(self) -> None:
        super().__init__()

        self.setWindowTitle("Line Style Demo")
        self.resize(600,400)

        self.customPlot = QCustomPlot(self)
        self.gridLayout = QGridLayout(self).addWidget(self.customPlot)

        self.customPlot.legend.setVisible(True)
        self.customPlot.legend.setFont(QFont("Helvetica", 9))
        pen = QPen()
        lineNames = ["lsNone", "lsLine", "lsStepLeft", "lsStepRight", "lsStepCenter", "lsImpulse"]
        # add graphs with different line styles:
        for i in range(QCPGraph.lsNone, QCPGraph.lsImpulse+1):
            self.customPlot.addGraph()
            pen.setColor(QColor(int(math.sin(i*1+1.2)*80+80), int(math.sin(i*0.3+0)*80+80), int(math.sin(i*0.3+1.5)*80+80)))
            self.customPlot.graph().setPen(pen)
            self.customPlot.graph().setName(lineNames[i-QCPGraph.lsNone])
            self.customPlot.graph().setLineStyle(QCPGraph.LineStyle(i))
            self.customPlot.graph().setScatterStyle(QCPScatterStyle(QCPScatterStyle.ssCircle, 5))
            # generate data:
            x = [j/15.0 * 5*3.14 + 0.01 for j in range(15)]
            y = [7*math.sin(x[j])/x[j] - (i-QCPGraph.lsNone)*5 + (QCPGraph.lsImpulse)*5 + 2 for j in range(15)]
            self.customPlot.graph().setData(x, y)
            self.customPlot.graph().rescaleAxes(True)
        # zoom out a bit:
        self.customPlot.yAxis.scaleRange(1.1, self.customPlot.yAxis.range().center())
        self.customPlot.xAxis.scaleRange(1.1, self.customPlot.xAxis.range().center())
        # set blank axis lines:
        self.customPlot.xAxis.setTicks(False)
        self.customPlot.yAxis.setTicks(True)
        self.customPlot.xAxis.setTickLabels(False)
        self.customPlot.yAxis.setTickLabels(True)
        # make top right axes clones of bottom left axes:
        self.customPlot.axisRect().setupFullAxesBox()

if __name__ == '__main__':
    app = QApplication(sys.argv)
    mainForm = MainForm()
    mainForm.show()
    sys.exit(app.exec())

Date Axis Demo

Random walks with fill and smart date ticks on the bottom axis

import sys, math, random

from PyQt5.QtWidgets import QApplication, QGridLayout, QWidget
from PyQt5.QtGui import QPen, QColor, QBrush, QFont
from PyQt5.QtCore import QDateTime, QLocale
from QCustomPlot_PyQt5 import QCustomPlot, QCPGraph, QCPGraphData, QCPAxisTickerText, QCPAxisTickerDateTime

class MainForm(QWidget):

    def __init__(self) -> None:
        super().__init__()

        self.setWindowTitle("Date Axis Demo")
        self.resize(600,400)

        self.customPlot = QCustomPlot(self)
        self.gridLayout = QGridLayout(self).addWidget(self.customPlot)

        # set locale to english, so we get english month names:
        self.customPlot.setLocale(QLocale(QLocale.English, QLocale.UnitedKingdom))
        # seconds of current time, we'll use it as starting point in time for data:
        self.now = QDateTime.currentDateTime().toTime_t()
        # create multiple graphs:
        for i in range(5):
            self.customPlot.addGraph()
            color = QColor(int(20+200/4.0*i), int(70*(1.6-i/4.0)), 150, 150)
            self.customPlot.graph().setLineStyle(QCPGraph.lsLine)
            self.customPlot.graph().setPen(QPen(color.lighter(200)))
            self.customPlot.graph().setBrush(QBrush(color))

            # generate random walk data:
            timeData = [QCPGraphData() for k in range(250)]
            for j in range(250):
                timeData[j].key = self.now + 24*3600*j
                if j == 0:
                    timeData[j].value = (j/50.0+1)*(random.random()/5.0-0.5)
                else:
                    timeData[j].value = math.fabs(timeData[j-1].value)*(1+0.02/4.0*(4-i)) + (j/50.0+1)*(random.random()-0.5)
            self.customPlot.graph().data().set(timeData)

        # configure bottom axis to show date instead of number:
        dateTicker = QCPAxisTickerDateTime()
        dateTicker.setDateTimeFormat("d. MMMM\nyyyy")
        self.customPlot.xAxis.setTicker(dateTicker)

        # configure left axis text labels:
        textTicker = QCPAxisTickerText()
        textTicker.addTick(10, "a bit\nlow")
        textTicker.addTick(50, "quite\nhigh")
        self.customPlot.yAxis.setTicker(textTicker)

        # set a more compact font size for bottom and left axis tick labels:
        self.customPlot.xAxis.setTickLabelFont(QFont(QFont().family(), 8))
        self.customPlot.yAxis.setTickLabelFont(QFont(QFont().family(), 8))

        # set axis labels:
        self.customPlot.xAxis.setLabel("Date")
        self.customPlot.yAxis.setLabel("Random wobbly lines value")

        # make top and right axes visible but without ticks and labels:
        self.customPlot.xAxis2.setVisible(True)
        self.customPlot.yAxis2.setVisible(True)
        self.customPlot.xAxis2.setTicks(False)
        self.customPlot.yAxis2.setTicks(False)
        self.customPlot.xAxis2.setTickLabels(False)
        self.customPlot.yAxis2.setTickLabels(False)

        # set axis ranges to show all data:
        self.customPlot.xAxis.setRange(self.now, self.now+24*3600*249)
        self.customPlot.yAxis.setRange(0, 60)

        # show legend with slightly transparent background brush:
        self.customPlot.legend.setVisible(True)
        self.customPlot.legend.setBrush(QColor(255, 255, 255, 150))

if __name__ == '__main__':
    app = QApplication(sys.argv)
    mainForm = MainForm()
    mainForm.show()
    sys.exit(app.exec())

Parametric Curves Demo

Parametric curves with translucent gradient filling

import sys, math

from PyQt5.QtWidgets import QApplication, QGridLayout, QWidget
from PyQt5.QtGui import QPen, QColor, QBrush, QRadialGradient
from PyQt5.QtCore import QPointF
from QCustomPlot_PyQt5 import QCustomPlot, QCP, QCPCurve, QCPCurveData

class MainForm(QWidget):

    def __init__(self) -> None:
        super().__init__()

        self.setWindowTitle("Parametric Curves Demo")
        self.resize(600,400)

        self.customPlot = QCustomPlot(self)
        self.gridLayout = QGridLayout(self).addWidget(self.customPlot)

        # create empty curve objects:
        self.fermatSpiral1 = QCPCurve(self.customPlot.xAxis, self.customPlot.yAxis)
        self.fermatSpiral2 = QCPCurve(self.customPlot.xAxis, self.customPlot.yAxis)
        self.deltoidRadial = QCPCurve(self.customPlot.xAxis, self.customPlot.yAxis)

        # generate the curve data points:
        pointCount = 500
        dataSpiral1 = [QCPCurveData() for i in range(pointCount)]
        dataSpiral2 = [QCPCurveData() for i in range(pointCount)]
        dataDeltoid = [QCPCurveData() for i in range(pointCount)]
        for i in range(pointCount):
            phi = i/(pointCount-1)*8*math.pi
            theta = i/(pointCount-1)*2*math.pi
            dataSpiral1[i] = QCPCurveData(i, math.sqrt(phi)*math.cos(phi), math.sqrt(phi)*math.sin(phi))
            dataSpiral2[i] = QCPCurveData(i, -dataSpiral1[i].key, -dataSpiral1[i].value)
            dataDeltoid[i] = QCPCurveData(i, 2*math.cos(2*theta)+math.cos(1*theta)+2*math.sin(theta), 2*math.sin(2*theta)-math.sin(1*theta))

        # pass the data to the curves; we know t (i in loop above) is ascending, so set alreadySorted=True (saves an extra internal sort):
        self.fermatSpiral1.data().set(dataSpiral1, True)
        self.fermatSpiral2.data().set(dataSpiral2, True)
        self.deltoidRadial.data().set(dataDeltoid, True)

        # color the curves:
        self.fermatSpiral1.setPen(QPen(QColor(0, 0, 255)))
        self.fermatSpiral1.setBrush(QBrush(QColor(0, 0, 255, 20)))
        self.fermatSpiral2.setPen(QPen(QColor(255, 120, 0)))
        self.fermatSpiral2.setBrush(QBrush(QColor(255, 120, 0, 30)))
        radialGrad = QRadialGradient(QPointF(310, 180), 200)
        radialGrad.setColorAt(0, QColor(170, 20, 240, 100))
        radialGrad.setColorAt(0.5, QColor(20, 10, 255, 40))
        radialGrad.setColorAt(1,QColor(120, 20, 240, 10))
        self.deltoidRadial.setPen(QPen(QColor(170, 20, 240)))
        self.deltoidRadial.setBrush(QBrush(radialGrad))

        # set some basic customPlot config:
        self.customPlot.setInteractions(QCP.iRangeDrag | QCP.iRangeZoom | QCP.iSelectPlottables)
        self.customPlot.axisRect().setupFullAxesBox()
        self.customPlot.rescaleAxes()

if __name__ == '__main__':
    app = QApplication(sys.argv)
    mainForm = MainForm()
    mainForm.show()
    sys.exit(app.exec())

Bar Chart Demo

Three stacked bar charts with manual x axis tick labels

import sys

from PyQt5.QtWidgets import QApplication, QGridLayout, QWidget
from PyQt5.QtGui import QPen, QColor, QBrush, QFont, QLinearGradient
from PyQt5.QtCore import Qt
from QCustomPlot_PyQt5 import QCustomPlot, QCPBars, QCP, QCPAxisTickerText

class MainForm(QWidget):

    def __init__(self) -> None:
        super().__init__()

        self.setWindowTitle("Bar Chart Demo")
        self.resize(600,400)

        self.customPlot = QCustomPlot(self)
        self.gridLayout = QGridLayout(self).addWidget(self.customPlot)

        # set dark background gradient:
        gradient = QLinearGradient(0, 0, 0, 400)
        gradient.setColorAt(0, QColor(90, 90, 90))
        gradient.setColorAt(0.38, QColor(105, 105, 105))
        gradient.setColorAt(1, QColor(70, 70, 70))
        self.customPlot.setBackground(QBrush(gradient))

        # create empty bar chart objects:
        self.regen = QCPBars(self.customPlot.xAxis, self.customPlot.yAxis)
        self.nuclear = QCPBars(self.customPlot.xAxis, self.customPlot.yAxis)
        self.fossil = QCPBars(self.customPlot.xAxis, self.customPlot.yAxis)
        self.regen.setAntialiased(False) # gives more crisp, pixel aligned bar borders
        self.nuclear.setAntialiased(False)
        self.fossil.setAntialiased(False)
        self.regen.setStackingGap(1)
        self.nuclear.setStackingGap(1)
        self.fossil.setStackingGap(1)
        # set names and colors:
        self.fossil.setName("Fossil fuels")
        self.fossil.setPen(QPen(QColor(111, 9, 176).lighter(170)))
        self.fossil.setBrush(QColor(111, 9, 176))
        self.nuclear.setName("Nuclear")
        self.nuclear.setPen(QPen(QColor(250, 170, 20).lighter(150)))
        self.nuclear.setBrush(QColor(250, 170, 20))
        self.regen.setName("Regenerative")
        self.regen.setPen(QPen(QColor(0, 168, 140).lighter(130)))
        self.regen.setBrush(QColor(0, 168, 140))
        # stack bars on top of each other:
        self.nuclear.moveAbove(self.fossil)
        self.regen.moveAbove(self.nuclear)

        # prepare x axis with country labels:
        ticks = [1, 2, 3, 4, 5, 6, 7]
        labels = ["USA", "Japan", "Germany", "France", "UK", "Italy", "Canada"]
        textTicker = QCPAxisTickerText()
        textTicker.addTicks(ticks, labels)
        self.customPlot.xAxis.setTicker(textTicker)
        self.customPlot.xAxis.setTickLabelRotation(60)
        self.customPlot.xAxis.setSubTicks(False)
        self.customPlot.xAxis.setTickLength(0, 4)
        self.customPlot.xAxis.setRange(0, 8)
        self.customPlot.xAxis.setBasePen(QPen(Qt.white))
        self.customPlot.xAxis.setTickPen(QPen(Qt.white))
        self.customPlot.xAxis.grid().setVisible(True)
        self.customPlot.xAxis.grid().setPen(QPen(QColor(130, 130, 130), 0, Qt.DotLine))
        self.customPlot.xAxis.setTickLabelColor(Qt.white)
        self.customPlot.xAxis.setLabelColor(Qt.white)

        # prepare y axis:
        self.customPlot.yAxis.setRange(0, 12.1)
        self.customPlot.yAxis.setPadding(5) # a bit more space to the left border
        self.customPlot.yAxis.setLabel("Power Consumption in\nKilowatts per Capita (2007)")
        self.customPlot.yAxis.setBasePen(QPen(Qt.white))
        self.customPlot.yAxis.setTickPen(QPen(Qt.white))
        self.customPlot.yAxis.setSubTickPen(QPen(Qt.white))
        self.customPlot.yAxis.grid().setSubGridVisible(True)
        self.customPlot.yAxis.setTickLabelColor(Qt.white)
        self.customPlot.yAxis.setLabelColor(Qt.white)
        self.customPlot.yAxis.grid().setPen(QPen(QColor(130, 130, 130), 0, Qt.SolidLine))
        self.customPlot.yAxis.grid().setSubGridPen(QPen(QColor(130, 130, 130), 0, Qt.DotLine))

        # Add data:
        self.fossilData  = [0.86*10.5, 0.83*5.5, 0.84*5.5, 0.52*5.8, 0.89*5.2, 0.90*4.2, 0.67*11.2]
        self.nuclearData = [0.08*10.5, 0.12*5.5, 0.40*5.8, 0.09*5.2, 0.00*4.2, 0.07*11.2]
        self.regenData   = [0.06*10.5, 0.05*5.5, 0.04*5.5, 0.06*5.8, 0.02*5.2, 0.07*4.2, 0.25*11.2]
        self.fossil.setData(ticks, self.fossilData)
        self.nuclear.setData(ticks, self.nuclearData)
        self.regen.setData(ticks, self.regenData)

        # setup legend:
        self.customPlot.legend.setVisible(True)
        self.customPlot.axisRect().insetLayout().setInsetAlignment(0, Qt.AlignTop|Qt.AlignHCenter)
        self.customPlot.legend.setBrush(QColor(255, 255, 255, 100))
        self.customPlot.legend.setBorderPen(QPen(Qt.PenStyle.NoPen))
        legendFont = QFont()
        legendFont.setPointSize(10)
        self.customPlot.legend.setFont(legendFont)
        self.customPlot.setInteractions(QCP.Interactions(QCP.iRangeDrag | QCP.iRangeZoom))

if __name__ == '__main__':
    app = QApplication(sys.argv)
    mainForm = MainForm()
    mainForm.show()
    sys.exit(app.exec())

Statistical Box Demo

Statistical 5-parameter-box-plot with outliers

import sys

from PyQt5.QtWidgets import QApplication, QGridLayout, QWidget
from PyQt5.QtGui import QColor, QBrush
from PyQt5.QtCore import Qt
from QCustomPlot_PyQt5 import QCustomPlot, QCPStatisticalBox, QCP, QCPAxisTickerText

class MainForm(QWidget):

    def __init__(self) -> None:
        super().__init__()

        self.setWindowTitle("Statistical Box Demo")
        self.resize(600,400)

        self.customPlot = QCustomPlot(self)
        self.gridLayout = QGridLayout(self).addWidget(self.customPlot)

        statistical = QCPStatisticalBox(self.customPlot.xAxis, self.customPlot.yAxis)
        boxBrush = QBrush(QColor(60, 60, 255, 100))
        boxBrush.setStyle(Qt.Dense6Pattern)  # make it look oldschool
        statistical.setBrush(boxBrush)

        # specify data:
        statistical.addData(1, 1.1, 1.9, 2.25, 2.7, 4.2)
        statistical.addData(2, 0.8, 1.6, 2.2, 3.2, 4.9, [0.7, 0.34, 0.45, 6.2, 5.84])  # provide some outliers as list
        statistical.addData(3, 0.2, 0.7, 1.1, 1.6, 2.9)

        # prepare manual x axis labels:
        self.customPlot.xAxis.setSubTicks(False)
        self.customPlot.xAxis.setTickLength(0, 4)
        self.customPlot.xAxis.setTickLabelRotation(20)
        textTicker = QCPAxisTickerText()
        textTicker.addTick(1, "Sample 1")
        textTicker.addTick(2, "Sample 2")
        textTicker.addTick(3, "Control Group")
        self.customPlot.xAxis.setTicker(textTicker)

        # prepare axes:
        self.customPlot.yAxis.setLabel("O₂ Absorption [mg]")
        self.customPlot.rescaleAxes()
        self.customPlot.xAxis.scaleRange(1.7, self.customPlot.xAxis.range().center())
        self.customPlot.yAxis.setRange(0, 7)
        self.customPlot.setInteractions(QCP.iRangeDrag | QCP.iRangeZoom)

if __name__ == '__main__':
    app = QApplication(sys.argv)
    mainForm = MainForm()
    mainForm.show()
    sys.exit(app.exec())

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:/a/719188.html

如若内容造成侵权/违法违规/事实不符,请联系我们进行投诉反馈qq邮箱809451989@qq.com,一经查实,立即删除!

相关文章

【一文开启StableDiffusion】最火AIGC绘画工具SD阿里云部署指南(含踩坑经验)

Midjonery使用简单,效果出色,不过需要付费。本文将介绍完全开源的另一款产品StableDiffusion,它的社区目前非常活跃,各种插件和微调模型都非常多,而且它无需付费注册,没有速度、网络限制,非常推…

广州巨控科技GRM230系列无线模块:环保监控的新利器*

​近日,广州巨控科技推出了一款功能强大的无线模块——GRM230系列,其独特的IO输入输出与485通讯功能,在环保、河道水质检测、流量液位无线4G传输等方面展现出显著的应用优势,尤其在远程泵站启停与监控领域取得了显著成效。 一、G…

有趣且重要的JS知识合集(22)树相关的算法

0、举例&#xff1a;树形结构原始数据 1、序列化树形结构 /*** 平铺序列化树形结构* param tree 树形结构* param result 转化后一维数组* returns Array<TreeNode>*/ export function flattenTree(tree, result []) {if (tree.length 0) {return result}for (const …

分数计算 中级题目

分数计算 中级题目&#xff1a;多个数参与的计算 参考答案&#xff1a;【仅供参考】CBBCCBCCCC

【语义分割系列】基于camvid数据集的Deeplabv3+分割算法(二)

基于camvid数据集的Deeplabv3+分割算法 前言 在前面的内容中,对比了Camvid数据集在基于不同backbone的Deeplabv3+算法上的效果。在这节内容中,本文将介绍在ghostnet的基础上,进一步优化效果,使得Miou提升。通过引入CFAC和CARAFE结构,有效地提升了模型的miou。 1.代码部…

国际期货投机交易的常见操作方法:

一、在开仓阶段&#xff0c;入市时机的选择&#xff1a; &#xff08;1&#xff09;通过基本分析法&#xff0c;判断市场处于牛市还是熊市 开仓阶段&#xff0c;入市时机的选择&#xff1a;当需求增加、供给减少&#xff0c;此时价格上升&#xff0c;买入期货合约&#xff1b…

Element-ui中Table表格无法显示

Element-ui中Table表格无法显示 在使用过程中发现样式正常显示但是table就是不显示&#xff0c;研究了一段时间后&#xff0c;发现问题是项目结构的问题 当你创建vue和安装el的时候&#xff0c;一定要注意进入到正确的项目文件夹&#xff0c;如果在外面也出现一个package.jso…

ARDUINO NRF24L01

连线 5v 3.3皆可 gnd Optimized high speed nRF24L01 driver class documentation: Optimized High Speed Driver for nRF24L01() 2.4GHz Wireless Transceiver 同时下载同一个程序 案例默认引脚ce ces &#xff0c;7&#xff0c;8 可以 修改为 9,10 安装库 第一个示例 两…

【driver8】

1.USB 2.磁盘缓存&#xff0c;页缓存 3.平均负载

传感器在智能家居中的应用

在物联网时代&#xff0c;智能家居成为人们生活中的重要组成部分。而传感器作为实现智能家居的基础设备&#xff0c;起到了关键的作用。不同类型的传感器能够获取环境中的各种参数&#xff0c;并通过物联网技术实现与智能家居系统的连接。例如&#xff0c;温度传感器可以实时监…

力扣每日一题 6/17 枚举+双指针

博客主页&#xff1a;誓则盟约系列专栏&#xff1a;IT竞赛 专栏关注博主&#xff0c;后期持续更新系列文章如果有错误感谢请大家批评指出&#xff0c;及时修改感谢大家点赞&#x1f44d;收藏⭐评论✍ 522.最长特殊序列II【中等】 题目&#xff1a; 给定字符串列表 strs &…

6.17作业

升级优化自己应用程序的登录界面。 要求&#xff1a; 1. qss实现 2. 需要有图层的叠加 &#xff08;QFrame&#xff09; 3. 设置纯净窗口后&#xff0c;有关闭等窗口功能。 4. 如果账号密码正确&#xff0c;则实现登录界面关闭&#xff0c;另一个应用界面显示。 //发送端头文件…

scratch3编程01-山地足球+射击游戏

目录 一&#xff0c;山地足球 1&#xff0c;基础&#xff08;需要的素材&#xff09; 1&#xff09;使用“重复执行直到”语句块 2&#xff09;使用“如果那么否则”语句 2&#xff0c;效果 3&#xff0c;sb3文件 一&#xff0c;击败小怪兽 1&#xff0c;基础&#xff0…

基于深度学习网络的USB摄像头实时视频采集与手势检测识别matlab仿真

目录 1.算法运行效果图预览 2.算法运行软件版本 3.部分核心程序 4.算法理论概述 4.1 系统架构 4.2 GoogLeNet网络简介 4.3 手势检测 5.算法完整程序工程 1.算法运行效果图预览 (完整程序运行后无水印) 训练过程如下&#xff1a; 将摄像头对准手势&#xff0c;然后进行…

HPC环境下文件流转最容易忽视的安全问题是什么?

半导体芯片设计企业将IC设计、仿真、验证过程上云&#xff0c;已成为越来越广泛的共识。企业使用HPC环境能满足 EDA 工作负载前端仿真百万随机 IO 小文件&#xff0c;后端仿真海量顺序读写大文件的高并发访问需求&#xff0c;简化 EDA 的工作流程&#xff0c;降低了仿真作业的时…

vue分类

先看效果 再看代码 <category-tab v-model"params.area" name"地区" :list"areaList" /><category-tab v-model"params.type" name"类型" :list"typeList" /><category-tab v-model"params.…

Semantic Kernel 中的流式输出SSE与Vue3前端接收示例

本文将介绍如何在使用 Semantic Kernel 框架的 ASP.NET 项目中使用流式输出 SSE&#xff08;Server-Sent Events&#xff09;&#xff0c;并展示如何在Vue3前端应用中接收这些数据。并介绍了如何使用 microsoft/fetch-event-source 库使用 POST 方法来接收 SSE 数据。 1. 背景 …

【单片机毕业设计选题24013】-基于STM32的城市垃圾分类引导系统

系统功能: 1、系统具有语音识别功能&#xff0c;可以对厨余垃圾、其他垃圾、有害垃圾、可回收垃圾进行语音识别&#xff1b; 2、系统可根据语音识别结果直接开启对应类别的垃圾桶&#xff0c;引导分类投放&#xff1b; 3、系统具有语音播报功能&#xff0c;可以语音播报出识…

Dapr分布式应用运行时初探2

Dapr是一个很优秀的分布式应用运行时&#xff0c;在本篇里我们来说一下Dapr的几个特色功能。 为了方便介绍&#xff0c;我简单画了个思维导图&#xff0c;如下所示&#xff1a; 众所周知&#xff0c;新技术的产生是为了解决现存的问题。从上面的思维图中我们可以了解下Dapr这…

【x264】滤波模块的简单分析

【x264】滤波模块的简单分析 1. 滤波模块概述1.1 自适应边界1.2 自适应样点级滤波器1.3 滤波过程 2. 函数入口&#xff08;fdec_filter_row&#xff09;2.1 去块滤波&#xff08;x264_frame_deblock_row&#xff09;2.1.1 强滤波函数&#xff08;deblock_edge_intra&#xff09…