C#语言实例源码系列-鼠标设置

news2024/11/16 21:58:21
专栏分享
  • 点击跳转=>Unity3D特效百例
  • 点击跳转=>案例项目实战源码
  • 点击跳转=>游戏脚本-辅助自动化
  • 点击跳转=>Android控件全解手册

👉关于作者

众所周知,人生是一个漫长的流程,不断克服困难,不断反思前进的过程。在这个过程中会产生很多对于人生的质疑和思考,于是我决定将自己的思考,经验和故事全部分享出来,以此寻找共鸣 !!!
专注于Android/Unity和各种游戏开发技巧,以及各种资源分享(网站、工具、素材、源码、游戏等)
有什么需要欢迎私我,交流群让学习不再孤单

在这里插入图片描述

👉实践过程

😜效果

在这里插入图片描述

😜代码

public partial class Form1 : Form
{
    public Form1()
    {
        InitializeComponent();
    }

    [System.Runtime.InteropServices.DllImport("user32.dll", EntryPoint = "SwapMouseButton")]
    public extern static int SwapMouseButton(int bSwap);
    [System.Runtime.InteropServices.DllImport("user32.dll", EntryPoint = "SystemParametersInfo")]
    public static extern bool SystemParametersInfo(uint uiAction, uint uiParam, ref int pvParam, uint fWinIni);
    [System.Runtime.InteropServices.DllImport("user32.dll")]
    public extern static int GetSystemMetrics(int nIndes);
    [System.Runtime.InteropServices.DllImport("user32.dll", EntryPoint = "SetDoubleClickTime")]
    public extern static int SetDoubleClickTime(int wCount);
    [System.Runtime.InteropServices.DllImport("user32.dll", EntryPoint = "GetDoubleClickTime")]
    public extern static int GetDoubleClickTime();

    const int SM_SWAPBUTTON = 23;//如左右鼠标键已经交换,则为TRUE
    const int SPI_SETMOUSE = 4;//设置鼠标的移动速度
    const int SPI_GETMOUSESPEED = 112;//检索当前鼠标速度
    const uint SPIF_UPDATEINIFILE = 0x0001;//更新win.ini和(或)注册表中的用户配置文件
    const uint SPIF_SENDWININICHANGE = 0x0002;//该消息告诉应用程序已经改变了用户配置设置
    int aMouseinfo=0;
    

    private void Form1_Load(object sender, EventArgs e)
    {
        if (GetSystemMetrics(SM_SWAPBUTTON) == 0)//如果鼠标的左右键没有切换
        {
            pictureBox1.Image = null;//清空图片
            pictureBox1.Image = Properties.Resources.鼠标左键;//显示图片
            checkBox1.Checked = false;//设置复选框为不选中状态
        }
        else//如果鼠标左右切换
        {
            pictureBox1.Image = null;//清空图片
            pictureBox1.Image = Properties.Resources.鼠标右键;//显示图片
            checkBox1.Checked = true;//设置复选框为选中状态
        }
        int tem_n = 0;
        switch (Convert.ToInt32(DoubleClickTime_Get()))//获取鼠标的双击速度
        {
            case 900: tem_n = 0; break;
            case 830: tem_n = 1; break;
            case 760: tem_n = 2; break;
            case 690: tem_n = 3; break;
            case 620: tem_n = 4; break;
            case 550: tem_n = 5; break;
            case 480: tem_n = 6; break;
            case 410: tem_n = 7; break;
            case 340: tem_n = 8; break;
            case 270: tem_n = 9; break;
            case 200: tem_n = 10; break;
        }
        trackBar1.Value = tem_n;//显示鼠标的双击速度
        SystemParametersInfo(SPI_GETMOUSESPEED, 0, ref aMouseinfo, 0);//获取当前鼠标的移动速度
        trackBar2.Value = aMouseinfo;//显示当前鼠标的移动速度
    }

    public string DoubleClickTime_Get()
    {
        return GetDoubleClickTime().ToString();//获取鼠标的双击速度
    }

    public void DoubleClickTime_Set(int MouseDoubleClickTime)
    {
        SetDoubleClickTime(MouseDoubleClickTime);//设置获取鼠标的双击速度
    }

    private void checkBox1_MouseUp(object sender, MouseEventArgs e)
    {
        if (((CheckBox)sender).Checked == true)//如果为选中状态
        {
            pictureBox1.Image = null;//清空图片
            pictureBox1.Image = Properties.Resources.鼠标右键;//显示图片
            SwapMouseButton(1);//切换鼠标左右键
        }
        else//如果不为选中状态
        {
            if (((CheckBox)sender).Checked == false)
            {
                pictureBox1.Image = null;//清空图片
                pictureBox1.Image = Properties.Resources.鼠标左键;//显示图片
                SwapMouseButton(0);//恢复,设置左键为主键
            }
        }
    }

    private void trackBar1_Scroll(object sender, EventArgs e)
    {
        int tem_n = 0;
        switch (((TrackBar)sender).Value)//记录鼠标的双击速度
        {
            case 0: tem_n = 900; break;
            case 1: tem_n = 830; break;
            case 2: tem_n = 760; break;
            case 3: tem_n = 690; break;
            case 4: tem_n = 620; break;
            case 5: tem_n = 550; break;
            case 6: tem_n = 480; break;
            case 7: tem_n = 410; break;
            case 8: tem_n = 340; break;
            case 9: tem_n = 270; break;
            case 10: tem_n = 200; break;
        }
        DoubleClickTime_Set(tem_n);//设置鼠标的双击的速度
    }

    private void trackBar2_Scroll(object sender, EventArgs e)
    {
        aMouseinfo = trackBar2.Value;//记录鼠标的移动速度
        SystemParametersInfo(SPI_SETMOUSE, 0, ref aMouseinfo, SPIF_UPDATEINIFILE);//设置鼠标的移动速度
    }
}
partial class Form1
{
    /// <summary>
    /// 必需的设计器变量。
    /// </summary>
    private System.ComponentModel.IContainer components = null;

    /// <summary>
    /// 清理所有正在使用的资源。
    /// </summary>
    /// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
    protected override void Dispose(bool disposing)
    {
        if (disposing && (components != null))
        {
            components.Dispose();
        }
        base.Dispose(disposing);
    }

    #region Windows 窗体设计器生成的代码

    /// <summary>
    /// 设计器支持所需的方法 - 不要
    /// 使用代码编辑器修改此方法的内容。
    /// </summary>
    private void InitializeComponent()
    {
        this.groupBox1 = new System.Windows.Forms.GroupBox();
        this.textBox1 = new System.Windows.Forms.TextBox();
        this.checkBox1 = new System.Windows.Forms.CheckBox();
        this.groupBox2 = new System.Windows.Forms.GroupBox();
        this.label3 = new System.Windows.Forms.Label();
        this.label2 = new System.Windows.Forms.Label();
        this.label1 = new System.Windows.Forms.Label();
        this.trackBar1 = new System.Windows.Forms.TrackBar();
        this.textBox2 = new System.Windows.Forms.TextBox();
        this.groupBox3 = new System.Windows.Forms.GroupBox();
        this.trackBar2 = new System.Windows.Forms.TrackBar();
        this.pictureBox3 = new System.Windows.Forms.PictureBox();
        this.pictureBox2 = new System.Windows.Forms.PictureBox();
        this.pictureBox1 = new System.Windows.Forms.PictureBox();
        this.label4 = new System.Windows.Forms.Label();
        this.label5 = new System.Windows.Forms.Label();
        this.label6 = new System.Windows.Forms.Label();
        this.groupBox1.SuspendLayout();
        this.groupBox2.SuspendLayout();
        ((System.ComponentModel.ISupportInitialize)(this.trackBar1)).BeginInit();
        this.groupBox3.SuspendLayout();
        ((System.ComponentModel.ISupportInitialize)(this.trackBar2)).BeginInit();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox3)).BeginInit();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).BeginInit();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
        this.SuspendLayout();
        // 
        // groupBox1
        // 
        this.groupBox1.Controls.Add(this.pictureBox1);
        this.groupBox1.Controls.Add(this.textBox1);
        this.groupBox1.Controls.Add(this.checkBox1);
        this.groupBox1.Location = new System.Drawing.Point(12, 12);
        this.groupBox1.Name = "groupBox1";
        this.groupBox1.Size = new System.Drawing.Size(376, 131);
        this.groupBox1.TabIndex = 0;
        this.groupBox1.TabStop = false;
        this.groupBox1.Text = "鼠标键配置";
        // 
        // textBox1
        // 
        this.textBox1.BackColor = System.Drawing.Color.WhiteSmoke;
        this.textBox1.BorderStyle = System.Windows.Forms.BorderStyle.None;
        this.textBox1.Location = new System.Drawing.Point(15, 51);
        this.textBox1.Multiline = true;
        this.textBox1.Name = "textBox1";
        this.textBox1.ReadOnly = true;
        this.textBox1.Size = new System.Drawing.Size(230, 28);
        this.textBox1.TabIndex = 3;
        this.textBox1.Text = "选择些复选框来将右按钮设成用于主要功能如选择和拖放之用";
        // 
        // checkBox1
        // 
        this.checkBox1.AutoSize = true;
        this.checkBox1.Location = new System.Drawing.Point(15, 29);
        this.checkBox1.Name = "checkBox1";
        this.checkBox1.Size = new System.Drawing.Size(144, 16);
        this.checkBox1.TabIndex = 0;
        this.checkBox1.Text = "切换主要和次要的按钮";
        this.checkBox1.UseVisualStyleBackColor = true;
        this.checkBox1.MouseUp += new System.Windows.Forms.MouseEventHandler(this.checkBox1_MouseUp);
        // 
        // groupBox2
        // 
        this.groupBox2.Controls.Add(this.pictureBox2);
        this.groupBox2.Controls.Add(this.label3);
        this.groupBox2.Controls.Add(this.label2);
        this.groupBox2.Controls.Add(this.label1);
        this.groupBox2.Controls.Add(this.trackBar1);
        this.groupBox2.Controls.Add(this.textBox2);
        this.groupBox2.Location = new System.Drawing.Point(12, 149);
        this.groupBox2.Name = "groupBox2";
        this.groupBox2.Size = new System.Drawing.Size(376, 100);
        this.groupBox2.TabIndex = 1;
        this.groupBox2.TabStop = false;
        this.groupBox2.Text = "双击速度";
        // 
        // label3
        // 
        this.label3.AutoSize = true;
        this.label3.Location = new System.Drawing.Point(227, 62);
        this.label3.Name = "label3";
        this.label3.Size = new System.Drawing.Size(17, 12);
        this.label3.TabIndex = 4;
        this.label3.Text = "快";
        // 
        // label2
        // 
        this.label2.AutoSize = true;
        this.label2.Location = new System.Drawing.Point(78, 62);
        this.label2.Name = "label2";
        this.label2.Size = new System.Drawing.Size(17, 12);
        this.label2.TabIndex = 3;
        this.label2.Text = "慢";
        // 
        // label1
        // 
        this.label1.AutoSize = true;
        this.label1.Location = new System.Drawing.Point(13, 60);
        this.label1.Name = "label1";
        this.label1.Size = new System.Drawing.Size(59, 12);
        this.label1.TabIndex = 2;
        this.label1.Text = "速度(D):";
        // 
        // trackBar1
        // 
        this.trackBar1.AutoSize = false;
        this.trackBar1.Location = new System.Drawing.Point(97, 56);
        this.trackBar1.Name = "trackBar1";
        this.trackBar1.Size = new System.Drawing.Size(126, 30);
        this.trackBar1.TabIndex = 1;
        this.trackBar1.Scroll += new System.EventHandler(this.trackBar1_Scroll);
        // 
        // textBox2
        // 
        this.textBox2.BackColor = System.Drawing.Color.WhiteSmoke;
        this.textBox2.BorderStyle = System.Windows.Forms.BorderStyle.None;
        this.textBox2.Location = new System.Drawing.Point(15, 20);
        this.textBox2.Multiline = true;
        this.textBox2.Name = "textBox2";
        this.textBox2.ReadOnly = true;
        this.textBox2.Size = new System.Drawing.Size(230, 30);
        this.textBox2.TabIndex = 0;
        this.textBox2.Text = "双击文件夹以检测您的设置。如文件夹没打开或关闭,请用慢一点的设置再试一资。";
        // 
        // groupBox3
        // 
        this.groupBox3.Controls.Add(this.label6);
        this.groupBox3.Controls.Add(this.label5);
        this.groupBox3.Controls.Add(this.label4);
        this.groupBox3.Controls.Add(this.pictureBox3);
        this.groupBox3.Controls.Add(this.trackBar2);
        this.groupBox3.Location = new System.Drawing.Point(12, 255);
        this.groupBox3.Name = "groupBox3";
        this.groupBox3.Size = new System.Drawing.Size(376, 93);
        this.groupBox3.TabIndex = 2;
        this.groupBox3.TabStop = false;
        this.groupBox3.Text = "移动";
        // 
        // trackBar2
        // 
        this.trackBar2.AutoSize = false;
        this.trackBar2.Location = new System.Drawing.Point(108, 49);
        this.trackBar2.Maximum = 20;
        this.trackBar2.Minimum = 1;
        this.trackBar2.Name = "trackBar2";
        this.trackBar2.Size = new System.Drawing.Size(148, 34);
        this.trackBar2.TabIndex = 0;
        this.trackBar2.Value = 1;
        this.trackBar2.Scroll += new System.EventHandler(this.trackBar2_Scroll);
        // 
        // pictureBox3
        // 
        this.pictureBox3.Image = global::鼠标设置器.Properties.Resources.移动;
        this.pictureBox3.Location = new System.Drawing.Point(15, 20);
        this.pictureBox3.Name = "pictureBox3";
        this.pictureBox3.Size = new System.Drawing.Size(43, 37);
        this.pictureBox3.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
        this.pictureBox3.TabIndex = 1;
        this.pictureBox3.TabStop = false;
        // 
        // pictureBox2
        // 
        this.pictureBox2.Image = global::鼠标设置器.Properties.Resources.文件夹;
        this.pictureBox2.Location = new System.Drawing.Point(301, 23);
        this.pictureBox2.Name = "pictureBox2";
        this.pictureBox2.Size = new System.Drawing.Size(60, 57);
        this.pictureBox2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
        this.pictureBox2.TabIndex = 5;
        this.pictureBox2.TabStop = false;
        // 
        // pictureBox1
        // 
        this.pictureBox1.Image = global::鼠标设置器.Properties.Resources.鼠标左键;
        this.pictureBox1.Location = new System.Drawing.Point(263, 18);
        this.pictureBox1.Name = "pictureBox1";
        this.pictureBox1.Size = new System.Drawing.Size(98, 101);
        this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize;
        this.pictureBox1.TabIndex = 4;
        this.pictureBox1.TabStop = false;
        // 
        // label4
        // 
        this.label4.AutoSize = true;
        this.label4.Location = new System.Drawing.Point(64, 20);
        this.label4.Name = "label4";
        this.label4.Size = new System.Drawing.Size(113, 12);
        this.label4.TabIndex = 2;
        this.label4.Text = "选择指针移动速度:";
        // 
        // label5
        // 
        this.label5.AutoSize = true;
        this.label5.Location = new System.Drawing.Point(87, 55);
        this.label5.Name = "label5";
        this.label5.Size = new System.Drawing.Size(17, 12);
        this.label5.TabIndex = 3;
        this.label5.Text = "慢";
        // 
        // label6
        // 
        this.label6.AutoSize = true;
        this.label6.Location = new System.Drawing.Point(260, 55);
        this.label6.Name = "label6";
        this.label6.Size = new System.Drawing.Size(17, 12);
        this.label6.TabIndex = 4;
        this.label6.Text = "快";
        // 
        // Form1
        // 
        this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
        this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
        this.BackColor = System.Drawing.Color.WhiteSmoke;
        this.ClientSize = new System.Drawing.Size(398, 358);
        this.Controls.Add(this.groupBox3);
        this.Controls.Add(this.groupBox2);
        this.Controls.Add(this.groupBox1);
        this.Name = "Form1";
        this.Text = "鼠标设置";
        this.Load += new System.EventHandler(this.Form1_Load);
        this.groupBox1.ResumeLayout(false);
        this.groupBox1.PerformLayout();
        this.groupBox2.ResumeLayout(false);
        this.groupBox2.PerformLayout();
        ((System.ComponentModel.ISupportInitialize)(this.trackBar1)).EndInit();
        this.groupBox3.ResumeLayout(false);
        this.groupBox3.PerformLayout();
        ((System.ComponentModel.ISupportInitialize)(this.trackBar2)).EndInit();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox3)).EndInit();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).EndInit();
        ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
        this.ResumeLayout(false);

    }

    #endregion

    private System.Windows.Forms.GroupBox groupBox1;
    private System.Windows.Forms.GroupBox groupBox2;
    private System.Windows.Forms.GroupBox groupBox3;
    private System.Windows.Forms.CheckBox checkBox1;
    private System.Windows.Forms.TextBox textBox1;
    private System.Windows.Forms.PictureBox pictureBox1;
    private System.Windows.Forms.TextBox textBox2;
    private System.Windows.Forms.Label label3;
    private System.Windows.Forms.Label label2;
    private System.Windows.Forms.Label label1;
    private System.Windows.Forms.TrackBar trackBar1;
    private System.Windows.Forms.PictureBox pictureBox2;
    private System.Windows.Forms.TrackBar trackBar2;
    private System.Windows.Forms.PictureBox pictureBox3;
    private System.Windows.Forms.Label label6;
    private System.Windows.Forms.Label label5;
    private System.Windows.Forms.Label label4;
}

需要的再直接Call我,直接发。

👉其他

📢作者:小空和小芝中的小空
📢转载说明-务必注明来源:https://zhima.blog.csdn.net/
📢这位道友请留步☁️,我观你气度不凡,谈吐间隐隐有王者霸气💚,日后定有一番大作为📝!!!旁边有点赞👍收藏🌟今日传你,点了吧,未来你成功☀️,我分文不取,若不成功⚡️,也好回来找我。

温馨提示点击下方卡片获取更多意想不到的资源。
空名先生

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

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

DDL(保姆级教学)

目录 DDL&#xff1a; 1、数据库的创建&#xff1a; 2、由于重复创建同名数据库会报错 3、注意如果默认字符集为Latin1,其不支持中文&#xff0c;所以改为&#xff1a; 数据库的创建&#xff1a; 数据表的创建 属性的数据类型 1、数值类型&#xff1a; 2、字符串类型&a…

离散数学-用以图转化为矩阵并且求出这个矩阵的最大度最小度

题目: 从键盘输入无向图的邻接矩阵&#xff0c;判断输出该图结点最大度数、最小度数。 问题的分析&#xff1a; 对于一个图的输入&#xff0c;你一定会去使用二维数组来进行数据的存储&#xff0c;那么第一步就是建立一个二维数组&#xff0c;然后来进行输入&#xff0c;我下…

广域网技术——SRv6隧道类型及数据转发

目录 SRv6节点 节点角色 节点行为 SRv6数据转发隧道建立方式 SRv6 BE L3VPNv4 over SRv6 BE EVPN L3VPNv6 over SRv6 BE SRv6 TE Policy SRv6使用IPv6数据平面&#xff0c;基于IPv6扩展头进行扩展实现类似标签转发的处理 SR-MPLS在建立SR-MPLS隧道时&#xff0c;如果有…

Windows版本的Redis(新版本的GitHub地址)

Redis通常被称为数据结构服务器&#xff0c;因为值&#xff08;value&#xff09;可以是字符串(String)、哈希(Hash)、列表(list)、集合(sets)和有序集合(sorted sets)等类型 Redis官网地址&#xff1a;Redis 关于Windows版本 Redis目前提供源码、Docker镜像、云版三种下载形…

利用@Retryable注解实现重试机制

Retryable 它可以作用在方法上&#xff0c;当方法抛出指定的异常时&#xff0c;整个方法将会被重新执行。在使用时需要先在pom.xml中导入相关依赖&#xff0c;再在启动类中添加EnableRetry注释以开启重试功能&#xff0c;最后在相应的方法上添加Retryable注释。 引入依赖 <…

【边缘检测】蚁群算法图像边缘检测【含Matlab源码 1189期】

⛄一、获取代码方式 获取代码方式1&#xff1a; 完整代码已上传我的资源&#xff1a;【边缘检测】基于matlab蚁群算法图像边缘检测【含Matlab源码 1189期】 获取代码方式2&#xff1a; 通过订阅紫极神光博客付费专栏&#xff0c;凭支付凭证&#xff0c;私信博主&#xff0c;可…

12.17 - 每日一题 - 408

每日一句&#xff1a; 我们生活在行动中&#xff0c;而不是生活在岁月里;我们生活在思想中&#xff0c;而不是生活在呼吸里。 数据结构 1 在有向图G的拓扑序列中&#xff0c;若顶点Vi在顶点Vj之前&#xff0c;则下列情形不可能出现的是______ A.G中有弧<Vi,Vj>B.G中有…

sqli-labs 通关笔记详解 Less1 - Less10

文章目录GET显错注入流程前置知识注入步骤GET盲注基本流程前置知识注入步骤Less - 1Less - 2Less - 3Less - 4Less - 5Less - 6Less - 7Less - 8Less - 10做sqli-labs靶场之前建议补一下基础 SQL注入简介和注入方法教学 Web安全基础-SQL MySQL SQLMAP工具 详细使用方法 GET显…

动态规划问题——换钱的最少货币数

题目&#xff1a; 给定数组arr&#xff0c;arr中所有的值都为正数且不重复。每个值代表一种面值的货币&#xff0c;每种面值的货币可以使用任意张&#xff0c;在给定一个整数aim&#xff0c;代表要找的钱数&#xff0c;求组成aim的最少货币数。 示例&#xff1a; arr [5,2,…

自动生成MySQL DDL建表语句

简介项目中大部分情况下都是使用MySQL数据&#xff0c;而且主要使用的数据库类型是char、varchar、date、datetime、timestamp、int、tinyint等几种常见的数据类型&#xff1b;而且进行表设计时&#xff0c;一般都要出一份表设计文档&#xff0c;例如表设计模板如下因为有了如此…

[附源码]Nodejs计算机毕业设计基于移动端的药方收集系统Express(程序+LW)

该项目含有源码、文档、程序、数据库、配套开发软件、软件安装教程。欢迎交流 项目运行 环境配置&#xff1a; Node.js Vscode Mysql5.7 HBuilderXNavicat11VueExpress。 项目技术&#xff1a; Express框架 Node.js Vue 等等组成&#xff0c;B/S模式 Vscode管理前后端分…

【Spring】一文带你吃透IOC容器技术

目录 一、前言 二、IOC容器技术 1、ioc概念 2、DI依赖注入 2.1、构造注入依赖 2.2、setter注入依赖 3、ioc底层实现 4、基于xml配置声明Bean以及使用 4.1、根节点标签beans 4.2、声明Bean 4.3、Bean的使用 5、面向接口编程 5.1、新增接口IOrderService 5.2、Order…

非零基础自学Golang 第11章 文件操作 11.2 文件基本操作 11.2.2 文件读取

非零基础自学Golang 文章目录非零基础自学Golang第11章 文件操作11.2 文件基本操作11.2.2 文件读取第11章 文件操作 11.2 文件基本操作 11.2.2 文件读取 想要读取文件可以使用os库中的Read接口&#xff1a; func (f &#xff0a;File) Read(b []byte) (n int, err error)Re…

RCNN网络源码解读(Ⅳ) --- 训练SVM二分类模型的准备过程

目录 1.回忆上一讲及本讲我们要做什么 2.回顾finetune是怎么训练的&#xff08;finetune.py&#xff09; 3. 训练SVM二分类模型 &#xff08;linear_svm.py&#xff09; 3.1 load_data 3.2 custom_classifier_dataset.py 3.3 custom_batch_sampler.py 3.4 hinge_loss 1…

python制作问题搜索解答器,从此学习无忧

前言 大家早好、午好、晚好吖 ❤ ~ 今天博主给大家带来一个问题搜索解答器&#xff01;&#xff01; 需要素材 以及一双慧手和一个灵活的脑子~ 效果展示 代码展示 导入模块 import requests import tkinter as tk from tkinter import ttk import webbrowserdef search(wor…

北京车牌那么难摇为什么还能那么受欢迎?

在北京生活的人来说一块北京车牌真的影响正常生活&#xff0c;特别是这两年的疫情反复...&#xff0c;面对房贷房租&#xff0c;衣食住行&#xff0c;就算外面世界再纷纷扰扰&#xff0c;也要面对...所以在北京生活没有一辆北京车牌汽车真的很麻烦。 对于在北京生活的人来说就…

【C语言刷题】PTA基础编程题目集精选

作者&#xff1a;匿名者Unit 专栏&#xff1a; 《C语言刷题》 目录题目精选6-7 统计某类完全平方数6-9 统计个位数字6-10 阶乘计算升级版6-11 求自定类型元素序列的中位数题目精选 6-7 统计某类完全平方数 我们先看一下题目要求&#xff1a; 根据题目给出的要求&#xff1a…

瑞格科技IPO被终止:曾拟募资5.6亿 江振翔三兄弟为实控人

雷递网 雷建平 12月17日浙江瑞格智能科技股份有限公司&#xff08;简称&#xff1a;“瑞格科技”&#xff09;日前IPO被终止。瑞格科技计划募资5.59亿元&#xff0c;其中&#xff0c;2.55亿元用于年产1000万套汽车配件技改项目&#xff0c;9240万元用于年产500万件智能传感器及…

css深度选择器deep

1.为什么要有deep 1.当我们给组件设置scoped的时候&#xff0c;此时我们组件的css样式只会对自己的内容生效&#xff0c;不会对子组件里面的内容生效。 <style lang"scss" scoped> .login-page {min-height: 100vh;background: url(/assets/login-bg.svg) no-r…

大脑网络的图论分析

利用图论测量大脑结构和功能网络的四个步骤: 定义网络节点——在脑电研究中&#xff0c;电极天然形成节点&#xff1b;在磁共振研究中&#xff0c;可以使用不同的脑图谱作为节点或者基于体素水平进行研究估计节点之间的连接性——结构上&#xff0c;可以由DTI计算两个脑区之间…