828华为云征文 | 深度评测,华为云Flexus X实例在Sysbench性能测试中的亮眼表现

news2024/9/19 23:24:52

前言

本文章评测了华为云Flexus X实例在Sysbench性能测试中的亮眼表现。Flexus X凭借其新一代处理器和智能算力技术,在CPU、内存、磁盘I/O及网络性能上均展现出了卓越的能力。通过Sysbench的详尽测试,Flexus X实例在多核计算能力、内存吞吐量、磁盘响应速度及吞吐能力方面均获得了高分。其高主频、多核支持以及智能资源调配机制,确保了在各种工作负载下的稳定高效运行。无论是电商直播、企业建站还是个人开发测试,Flexus X实例都能提供稳定可靠的性能支持。立即上云,选择Flexus X,开启您的数字化转型之旅!
链接直达华为云Flexus云服务器X实例

在这里插入图片描述

sysbench介绍

Sysbench是一款功能强大的开源性能测试工具,支持跨平台操作,专注于评估数据库(如MySQL、PostgreSQL等)及系统其他组件(CPU、内存、文件I/O等)在高负载下的性能表现。通过提供丰富的测试选项和统计数据,Sysbench帮助用户发现系统瓶颈,优化性能配置,并满足特定的测试需求。其易于使用和可扩展性使得它成为系统管理员和开发者在性能测试领域的首选工具之一。

sysbench包含以下内建的基准测试:

  • oltp_*.lua:一系列类似OLTP的数据库基准测试案例
  • fileio:文件系统级的基准测试
  • cpu:一个简单的CPU性能测试
  • memory:内存访问性能测试
  • threads:基于线程的调度器测试
  • mutex:POSIX互斥锁性能测试

项目开源地址:https://github.com/akopytov/sysbench

在这里插入图片描述

安装sysbench

在线安装

[root@flexusx-251f ~]# curl -s https://packagecloud.io/install/repositories/akopytov/sysbench/script.rpm.sh | sudo bash
[root@flexusx-251f ~]# sudo yum -y install sysbench

验证是否安装成功

[root@flexusx-251f ~]# sysbench --version
sysbench 1.0.20

离线安装

如果因为网络问题导致不能拉取源文件,可以手动导入,点击下载源文件

# 可以看到导入成功
[root@flexusx-251f yum.repos.d]# ls
akopytov_sysbench.repo  docker-ce.repo  hce.repo  mysql-community.repo  mysql-community-source.repo

# 清理缓存
[root@flexusx-251f sysbench]# yum clean all
34 files removed

# 构建缓存,并进行gpg验证
[root@flexusx-251f sysbench]# yum makecache
akopytov_sysbench                                                                                                                 164  B/s | 833  B     00:05
akopytov_sysbench                                                                                                                 2.0 kB/s | 3.9 kB     00:01
Importing GPG key 0x04DCFD39:
 Userid     : "https://packagecloud.io/akopytov/sysbench-prerelease (https://packagecloud.io/docs#gpg_signing) <support@packagecloud.io>"
 Fingerprint: 9789 8D69 F99E E5CA C462 A0F8 CF10 4890 04DC FD39
 From       : https://packagecloud.io/akopytov/sysbench/gpgkey
Is this ok [y/N]: y        # 输入y
akopytov_sysbench                                                                                                                 998  B/s | 6.5 kB     00:06
akopytov_sysbench-source                                                                                                          224  B/s | 833  B     00:03
akopytov_sysbench-source                                                                                                          4.1 kB/s | 3.9 kB     00:00
Importing GPG key 0x04DCFD39:
 Userid     : "https://packagecloud.io/akopytov/sysbench-prerelease (https://packagecloud.io/docs#gpg_signing) <support@packagecloud.io>"
 Fingerprint: 9789 8D69 F99E E5CA C462 A0F8 CF10 4890 04DC FD39
 From       : https://packagecloud.io/akopytov/sysbench/gpgkey
Is this ok [y/N]: y        # 输入y
akopytov_sysbench-source                                                                                                          264  B/s | 1.3 kB     00:05
Docker CE Stable - x86_64                                                                                                         448 kB/s |  53 kB     00:00
HCE 2.0 base                                                                                                                       66 MB/s | 6.1 MB     00:00
HCE 2.0 updates                                                                                                                   1.9 MB/s |  14 MB     00:07
MySQL Connectors Community                                                                                                         82 kB/s |  74 kB     00:00
MySQL Tools Community                                                                                                              56 kB/s | 1.3 MB     00:24
MySQL 5.7 Community Server                                                                                                        164 kB/s | 3.1 MB     00:19
Metadata cache created.

# 执行命令进行安装
[root@flexusx-251f sysbench]# yum -y install sysbench
Last metadata expiration check: 0:03:36 ago on Thu 19 Sep 2024 04:44:05 PM CST.
Dependencies resolved.
==================================================================================================================================================================
 Package                                    Architecture                  Version                                  Repository                                Size
==================================================================================================================================================================
Installing:
 sysbench                                   x86_64                        1.0.20-1.el8                             akopytov_sysbench                        443 k
Installing dependencies:
 libpq                                      x86_64                        13.12-1.hce2                             updates                                  194 k
 mariadb-connector-c                        x86_64                        3.1.13-1.r2.hce2                         updates                                  184 k

Transaction Summary
==================================================================================================================================================================
Install  3 Packages

Total download size: 822 k
Installed size: 2.4 M
Downloading Packages:
(1/3): mariadb-connector-c-3.1.13-1.r2.hce2.x86_64.rpm                                                                            4.0 MB/s | 184 kB     00:00
(2/3): libpq-13.12-1.hce2.x86_64.rpm                                                                                              3.8 MB/s | 194 kB     00:00
(3/3): sysbench-1.0.20-1.el8.x86_64.rpm                                                                                           153 kB/s | 443 kB     00:02
------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                             284 kB/s | 822 kB     00:02
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Running scriptlet: mariadb-connector-c-3.1.13-1.r2.hce2.x86_64                                                                                              1/1
  Preparing        :                                                                                                                                          1/1
  Installing       : mariadb-connector-c-3.1.13-1.r2.hce2.x86_64                                                                                              1/3
  Installing       : libpq-13.12-1.hce2.x86_64                                                                                                                2/3
  Installing       : sysbench-1.0.20-1.el8.x86_64                                                                                                             3/3
  Running scriptlet: sysbench-1.0.20-1.el8.x86_64                                                                                                             3/3
  Verifying        : sysbench-1.0.20-1.el8.x86_64                                                                                                             1/3
  Verifying        : libpq-13.12-1.hce2.x86_64                                                                                                                2/3
  Verifying        : mariadb-connector-c-3.1.13-1.r2.hce2.x86_64                                                                                              3/3

Installed:
  libpq-13.12-1.hce2.x86_64                     mariadb-connector-c-3.1.13-1.r2.hce2.x86_64                     sysbench-1.0.20-1.el8.x86_64

Complete!

验证是否安装成功

[root@flexusx-251f ~]# sysbench --version
sysbench 1.0.20

帮助命令

[root@flexusx-251f ~]# sysbench --help
Usage:
  sysbench [options]... [testname] [command]

Commands implemented by most tests: prepare run cleanup help

General options:
  --threads=N                     number of threads to use [1]
  --events=N                      limit for total number of events [0]
  --time=N                        limit for total execution time in seconds [10]
  --forced-shutdown=STRING        number of seconds to wait after the --time lim              it before forcing shutdown, or 'off' to disable [off]
  --thread-stack-size=SIZE        size of stack per thread [64K]
  --rate=N                        average transactions rate. 0 for unlimited rat              e [0]
  --report-interval=N             periodically report intermediate statistics wi              th a specified interval in seconds. 0 disables intermediate reports [0]
  --report-checkpoints=[LIST,...] dump full statistics and reset all counters at               specified points in time. The argument is a list of comma-separated values repr              esenting the amount of time in seconds elapsed from start of test when report ch              eckpoint(s) must be performed. Report checkpoints are off by default. []
  --debug[=on|off]                print more debugging info [off]
  --validate[=on|off]             perform validation checks where possible [off]
  --help[=on|off]                 print help and exit [off]
  --version[=on|off]              print version and exit [off]
  --config-file=FILENAME          File containing command line options
  --tx-rate=N                     deprecated alias for --rate [0]
  --max-requests=N                deprecated alias for --events [0]
  --max-time=N                    deprecated alias for --time [0]
  --num-threads=N                 deprecated alias for --threads [1]

Pseudo-Random Numbers Generator options:
  --rand-type=STRING random numbers distribution {uniform,gaussian,special,paret              o} [special]
  --rand-spec-iter=N number of iterations used for numbers generation [12]
  --rand-spec-pct=N  percentage of values to be treated as 'special' (for specia              l distribution) [1]
  --rand-spec-res=N  percentage of 'special' values to use (for special distribu              tion) [75]
  --rand-seed=N      seed for random number generator. When 0, the current time               is used as a RNG seed. [0]
  --rand-pareto-h=N  parameter h for pareto distribution [0.2]

Log options:
  --verbosity=N verbosity level {5 - debug, 0 - only critical messages} [3]

  --percentile=N       percentile to calculate in latency statistics (1-100). Us              e the special value of 0 to disable percentile calculations [95]
  --histogram[=on|off] print latency histogram in report [off]

General database options:

  --db-driver=STRING  specifies database driver to use ('help' to get list of av              ailable drivers) [mysql]
  --db-ps-mode=STRING prepared statements usage mode {auto, disable} [auto]
  --db-debug[=on|off] print database-specific debug information [off]


Compiled-in database drivers:
  mysql - MySQL driver
  pgsql - PostgreSQL driver

mysql options:
  --mysql-host=[LIST,...]          MySQL server host [localhost]
  --mysql-port=[LIST,...]          MySQL server port [3306]
  --mysql-socket=[LIST,...]        MySQL socket
  --mysql-user=STRING              MySQL user [sbtest]
  --mysql-password=STRING          MySQL password []
  --mysql-db=STRING                MySQL database name [sbtest]
  --mysql-ssl[=on|off]             use SSL connections, if available in the clie              nt library [off]
  --mysql-ssl-cipher=STRING        use specific cipher for SSL connections []
  --mysql-compression[=on|off]     use compression, if available in the client l              ibrary [off]
  --mysql-debug[=on|off]           trace all client library calls [off]
  --mysql-ignore-errors=[LIST,...] list of errors to ignore, or "all" [1213,1020              ,1205]
  --mysql-dry-run[=on|off]         Dry run, pretend that all MySQL client API ca              lls are successful without executing them [off]

pgsql options:
  --pgsql-host=STRING     PostgreSQL server host [localhost]
  --pgsql-port=N          PostgreSQL server port [5432]
  --pgsql-user=STRING     PostgreSQL user [sbtest]
  --pgsql-password=STRING PostgreSQL password []
  --pgsql-db=STRING       PostgreSQL database name [sbtest]

Compiled-in tests:
  fileio - File I/O test
  cpu - CPU performance test
  memory - Memory functions speed test
  threads - Threads subsystem performance test
  mutex - Mutex performance test

See 'sysbench <testname> help' for a list of options for each test.

开始测试

CPU性能测试

参数命令解析:

  • –cpu-max-prime: 素数生成数量的上限 (默认值10000)
  • –threads: 线程数(默认值1)
  • –time: 运行时长,单位秒
# 素数上限2万,默认10秒,2个线程
[root@flexusx-251f ~]# sysbench --test=cpu --cpu-max-prime=20000 --threads=2 run
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Running the test with following options:
Number of threads: 2                                   # 两个线程(默认为1)
Initializing random number generator from current time


Prime numbers limit: 20000                  # 每个线程均产生2万个素数(默认10000)

Initializing worker threads...

Threads started!

CPU speed:
    events per second:  2271.63            # 所有线程每秒完成了

General statistics:
    total time:                          10.0009s    # 共耗时约10秒
    total number of events:              22722    # 10秒内所有线程一共完成了22722 event

Latency (ms):
         min:                                    0.87 
         avg:                                    0.88
         max:                                    8.92
         95th percentile:                        0.89
         sum:                                19994.63

Threads fairness:
    events (avg/stddev):           11361.0000/1.00
    execution time (avg/stddev):   9.9973/0.00

华为云flexusx实例云服务器在sysbench CPU性能测试中展现出强大的计算能力,以每秒2271.63个事件的高效率完成了2万个素数的生成和验证任务,总耗时约10秒,且延迟低、线程间负载均衡几乎完美,体现了该实例在处理高计算需求任务时的卓越性能。

线程测试

参数命令解析:

  • –thread-yields:每个请求产生多少线程,默认值100
  • –thread-locks: 每个线程锁的数量,默认值8
  • –num-threads: 发送请求线程的数量
# 64个测试线程请求,每个线程请求产生100个数量,每个线程的锁数量为2
[root@flexusx-251f ~]# sysbench --test=threads --num-threads=64 --thread-yields=100 --thread-locks=2 run
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
WARNING: --num-threads is deprecated, use --threads instead
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Running the test with following options:
Number of threads: 64
Initializing random number generator from current time


Initializing worker threads...

Threads started!


General statistics:
    total time:                          10.0034s
    total number of events:              77335

Latency (ms):
         min:                                    0.02
         avg:                                    8.28
         max:                                  166.09
         95th percentile:                       41.10
         sum:                               640087.96

Threads fairness:
    events (avg/stddev):           1208.3594/83.24
    execution time (avg/stddev):   10.0014/0.00

在华为云flexusx实例云服务器上进行的sysbench线程性能测试中,64个线程以平均每个线程产生1208个事件的速度高效运行,总耗时约10秒完成了77335个事件,尽管存在一定的延迟波动,但系统展现了良好的线程负载平衡能力,确保了整体性能的稳定和高效。

磁盘IO性能测试

准备测试数据

# 准备测试数据
[root@flexusx-251f ~]# sysbench --test=fileio --num-threads=16 --file-total-size=3G --file-test-mode=rndrw prepare
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
WARNING: --num-threads is deprecated, use --threads instead
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

128 files, 24576Kb each, 3072Mb total
Creating files for the test...
Extra file open flags: (none)
Creating file test_file.0
Creating file test_file.1
Creating file test_file.2
Creating file test_file.3
............................
Creating file test_file.125
Creating file test_file.126
Creating file test_file.127
3221225472 bytes written in 19.62 seconds (156.54 MiB/sec).

磁盘IO压测测试

# 磁盘IO压测测试(指定最大创建16个线程,创建的文件总大小为3G,文件读写模式为随机读。)
[root@flexusx-251f ~]# sysbench --test=fileio --num-threads=16 --file-total-size=3G --file-test-mode=rndrw run
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
WARNING: --num-threads is deprecated, use --threads instead
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Running the test with following options:
Number of threads: 16
Initializing random number generator from current time


Extra file open flags: (none)
128 files, 24MiB each
3GiB total file size
Block size 16KiB
Number of IO requests: 0
Read/Write ratio for combined random IO test: 1.50
Periodic FSYNC enabled, calling fsync() each 100 requests.
Calling fsync() at the end of test, Enabled.
Using synchronous I/O mode
Doing random r/w test
Initializing worker threads...

Threads started!


File operations:
    reads/s:                      7032.06
    writes/s:                     4687.25
    fsyncs/s:                     15190.90

Throughput:
    read, MiB/s:                  109.88
    written, MiB/s:               73.24

General statistics:
    total time:                          10.5196s
    total number of events:              281077

Latency (ms):
         min:                                    0.00
         avg:                                    0.59
         max:                                  593.86
         95th percentile:                        1.23
         sum:                               166993.52

Threads fairness:
    events (avg/stddev):           17567.3125/178.37
    execution time (avg/stddev):   10.4371/0.00

清理测试数据

# 清除测试数据
[root@flexusx-251f ~]# sysbench --test=fileio --num-threads=16 --file-total-size=3G --file-test-mode=rndrw cleanup
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
WARNING: --num-threads is deprecated, use --threads instead
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Removing test files...

通过sysbench工具在华为云flexusx实例云服务器上进行的磁盘IO性能测试表明,该服务器在16个线程并发执行随机读写操作时,实现了高达109.88 MiB/s的读取吞吐量和73.24 MiB/s的写入吞吐量,平均延迟仅为0.59毫秒,展现了卓越的性能和稳定性,充分验证了其在处理IO密集型任务时的高效能力。

内存测试

sysbench内存性能测试,主要是针对不同大小的块进行连续读写或者随机读写操作。在内存性能测试中,events指的是读/写一个内存块。

# 指定本次测试整个过程是在内存中传输 3G 的数据量,每个 block 大小为 8K,存储器存取方式为随机
[root@flexusx-251f ~]# sysbench --test=memory --memory-block-size=8k --memory-total-size=3G  --memory-access-mode=rnd  run
WARNING: the --test option is deprecated. You can pass a script name or path on the command line without any options.
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Running the test with following options:
Number of threads: 1
Initializing random number generator from current time


Running memory speed test with the following options:
  block size: 8KiB
  total size: 3072MiB
  operation: write
  scope: global

Initializing worker threads...

Threads started!

Total operations: 393216 (299501.95 per second)

3072.00 MiB transferred (2339.86 MiB/sec)


General statistics:
    total time:                          1.3113s
    total number of events:              393216

Latency (ms):
         min:                                    0.00
         avg:                                    0.00
         max:                                    0.03
         95th percentile:                        0.00
         sum:                                 1270.86

Threads fairness:
    events (avg/stddev):           393216.0000/0.00
    execution time (avg/stddev):   1.2709/0.00

华为云flexusx实例云服务器在内存性能测试中表现出色,通过sysbench工具以随机访问模式写入3GB数据,实现了高达2,339.86 MiB/sec的传输速率,全程耗时仅1.3秒,平均延迟几乎为零,最大延迟极低,且线程执行公平,充分展示了其卓越的内存处理能力和高效性能。

mysql数据库读写性能测试

创建数据库和用户

[root@flexusx-251f ~]# mysql -uroot -p
Enter password:

mysql> CREATE DATABASE sbtest;
Query OK, 1 row affected (0.00 sec)

mysql> CREATE USER 'sbuser'@'localhost' IDENTIFIED BY 'Abc123!@#';
Query OK, 0 rows affected (0.01 sec)

mysql> GRANT ALL PRIVILEGES ON sbtest.* TO 'sbuser'@'localhost';
Query OK, 0 rows affected (0.01 sec)

mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.01 sec)

准备Sysbench测试表,创建10张表,每张表个10万行,16线程

[root@flexusx-251f ~]# sysbench oltp_read_write --mysql-db=sbtest --mysql-user=sbuser --mysql-password='Abc123!@#' --tables=10 --table-size=100000 prepare
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Creating table 'sbtest1'...

Inserting 100000 records into 'sbtest1'
Creating a secondary index on 'sbtest1'...
Creating table 'sbtest2'...
Inserting 100000 records into 'sbtest2'
Creating a secondary index on 'sbtest2'...
Creating table 'sbtest3'...
Inserting 100000 records into 'sbtest3'
Creating a secondary index on 'sbtest3'...
Creating table 'sbtest4'...
Inserting 100000 records into 'sbtest4'
Creating a secondary index on 'sbtest4'...
Creating table 'sbtest5'...
Inserting 100000 records into 'sbtest5'
Creating a secondary index on 'sbtest5'...
Creating table 'sbtest6'...
Inserting 100000 records into 'sbtest6'
Creating a secondary index on 'sbtest6'...
Creating table 'sbtest7'...
Inserting 100000 records into 'sbtest7'
Creating a secondary index on 'sbtest7'...
Creating table 'sbtest8'...
Inserting 100000 records into 'sbtest8'
Creating a secondary index on 'sbtest8'...
Creating table 'sbtest9'...
Inserting 100000 records into 'sbtest9'
Creating a secondary index on 'sbtest9'...
Creating table 'sbtest10'...
Inserting 100000 records into 'sbtest10'
Creating a secondary index on 'sbtest10'...

运行测试

  • --threads=8表示使用8个线程来执行测试。
  • --time=30表示测试运行30秒。
  • --report-interval=10表示每10秒报告一次结果
[root@flexusx-251f ~]# sysbench oltp_read_write --mysql-db=sbtest --mysql-user=sbuser --mysql-password='Abc123!@#' --tables=10 --table-size=100000 --threads=8 --time=30 --report-interval=10 run
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Running the test with following options:
Number of threads: 8
Report intermediate results every 10 second(s)
Initializing random number generator from current time


Initializing worker threads...

Threads started!

[ 10s ] thds: 8 tps: 1900.81 qps: 38031.40 (r/w/o: 26622.54/7606.44/3802.42) lat (ms,95%): 8.58 err/s: 0.00 reconn/s: 0.00
[ 20s ] thds: 8 tps: 1974.71 qps: 39490.84 (r/w/o: 27644.40/7897.03/3949.41) lat (ms,95%): 7.98 err/s: 0.00 reconn/s: 0.00
[ 30s ] thds: 8 tps: 1992.49 qps: 39852.60 (r/w/o: 27896.36/7971.26/3984.98) lat (ms,95%): 7.30 err/s: 0.00 reconn/s: 0.00
SQL statistics:
    queries performed:
        read:                            821674
        write:                           234764
        other:                           117382
        total:                           1173820
    transactions:                        58691  (1956.00 per sec.)
    queries:                             1173820 (39119.99 per sec.)
    ignored errors:                      0      (0.00 per sec.)
    reconnects:                          0      (0.00 per sec.)

General statistics:
    total time:                          30.0042s
    total number of events:              58691

Latency (ms):
         min:                                    1.68
         avg:                                    4.09
         max:                                   49.22
         95th percentile:                        7.84
         sum:                               239943.20

Threads fairness:
    events (avg/stddev):           7336.3750/15.39
    execution time (avg/stddev):   29.9929/0.00

清理数据库

[root@flexusx-251f ~]# sysbench --threads=16 --time=600 --report-interval=1 --mysql-host=127.0.0.1 --mysql-port=3306 --mysql-db=sbtest --mysql-user=sbuser --mysql-password='Abc123!@#' --tables=10 --table-size=100000 oltp_read_write cleanup
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Dropping table 'sbtest1'...
Dropping table 'sbtest2'...
Dropping table 'sbtest3'...
Dropping table 'sbtest4'...
Dropping table 'sbtest5'...
Dropping table 'sbtest6'...
Dropping table 'sbtest7'...
Dropping table 'sbtest8'...
Dropping table 'sbtest9'...
Dropping table 'sbtest10'...

在华为云flexusx实例上,通过Sysbench工具对MySQL数据库进行了读写性能测试,成功创建了包含100万行数据的10张表,并在8线程并发下持续30秒,实现了每秒约1956笔事务处理,展现出优异的并发处理能力和低延迟特性,最终通过清理功能恢复了数据库整洁状态。这次测试全面评估了华为云flexusx实例上MySQL数据库在负载条件下的稳定性和性能表现。

体验和感受

深入评测了华为云Flexus X实例Sysbench性能测试中的卓越表现,这款面向中小企业和开发者的柔性算力云服务器,以其非凡的性能和灵活的资源配置能力,成为了云计算领域的璀璨明星。Flexus X实例Sysbench测试中,无论是CPU的多核计算能力、内存的吞吐量,还是磁盘I/O的响应速度和吞吐能力,均展现出了顶尖水平。其配备的最新一代处理器,结合智能算力技术,能够精准感知业务负载变化,自动调整资源配置,确保资源的高效利用。此外,Flexus X实例还支持多种特殊的CPU与内存配比,如1:3、2:5等,用户可根据实际需求灵活定制,实现“按需取用”,大大降低了资源浪费和成本支出。点击下方链接,立即行动吧!在828华为云企业上云节,携手Flexus X实例,共创数智化新篇章!

产品链接华为云Flexus云服务器X实例_直播_建站服务器-华为云

在这里插入图片描述

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

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

相关文章

CSS传统布局方法(补充)——WEB开发系列37

开发技术不断演进&#xff0c;布局方式也经历了多个阶段的变革。从最初的基于表格布局到 CSS 的浮动布局&#xff0c;再到今天的弹性盒&#xff08;Flexbox&#xff09;与 CSS Grid 网格布局&#xff0c;每一种布局方式都有其独特的背景和解决特定问题的优势。 一、CSS Grid 出…

neo4j安装启动教程+对应的jdk配置

参考这位博主的视频教程&#xff1a;neo4j社区windows版下载 一、官网下载neo4j的安装包 &#xff08;1&#xff09;官网下载页面 &#xff08;2&#xff09;上一步 【download】之后&#xff0c;会自动下载&#xff0c;如果没有&#xff0c;点击【here】 这里可以看到一行字…

IDEA Project不显示/缺失文件

问题&#xff1a;侧边栏project 模式下缺少部分文件 先点close project 打开项目所在目录&#xff0c;删除目录下的.idea文件夹 重新open project打开这个项目即可解决

stm32单片机个人学习笔记4(GPIO输入)

前言 本篇文章属于stm32单片机&#xff08;以下简称单片机&#xff09;的学习笔记&#xff0c;来源于B站教学视频。下面是这位up主的视频链接。本文为个人学习笔记&#xff0c;只能做参考&#xff0c;细节方面建议观看视频&#xff0c;肯定受益匪浅。 STM32入门教程-2023版 细…

JavaDS —— 图

图的概念 图是由顶点集合以及顶点之间的关系组成的一种数据结构&#xff1a;G &#xff08;V&#xff0c;E&#xff09; 其中 V 表示的是顶点集合 &#xff1a; V { x | x 属于某个数据对象集} 是有穷非空集合 E 叫做边的集合 &#xff1a; E {(x, y) | x, y 属于 V} 或者 …

深度长文:揭开C/C++三目运算符的全部秘密,助你写出更优雅的代码(下)

在上篇文章中&#xff0c;我们深入探讨了三目运算符的基础语法、与if-else的对比以及使用中的常见误区。通过这些知识&#xff0c;你已经掌握了如何在代码中使用三目运算符来简化条件判断。 然而&#xff0c;三目运算符在C和C中的应用并不仅限于简单的条件选择。接下来&#x…

尚品汇-秒杀下单实现-页面轮询查询订单状态(五十三)

目录&#xff1a; &#xff08;1&#xff09;整合秒杀业务 &#xff08;2&#xff09;秒杀下单 &#xff08;3&#xff09;秒杀下单监听 &#xff08;4&#xff09;页面轮询接口 &#xff08;1&#xff09;整合秒杀业务 秒杀的主要目的就是获取一个下单资格&#xff0c;拥…

《深度学习》—— 神经网络模型对手写数字的识别

神经网络模型对手写数字的识别 import torch from torch import nn # 导入神经网络模块 from torch.utils.data import DataLoader # 数据包管理工具&#xff0c;打包数据, from torchvision import datasets # 封装了很多与图像相关的模型&#xff0c;数据集 from torchvi…

codetop字符串刷题,刷穿地心!!不再畏惧!!暴打面试官!!

主要供自己回顾与复习&#xff0c;题源codetop标签字符串近半年&#xff0c;会不断更新 1.有效的括号字符串2.括号生成3.最长单词4.字符串转换整数(atoi)5.整数转罗马数字6.罗马数字转整数7.比较版本号8.最长公共前缀9.面试题17.15.最长单词10.验证IP地址11.面试题01.06.字符串…

介绍一下常用的激活函数?

常用的激活函数 Sigmoid函数Tanh函数ReLU函数Leaky ReLU函数Softmax函数 Sigmoid函数 特点&#xff1a; 将任意实数映射到(0,1)区间内&#xff0c;输出值可以作为概率来解释。 函数平滑且易于求导&#xff0c;但其导数在两端趋近于0&#xff0c;即存在梯度消失问题。 输出值不…

CWFED:自然灾害检测数据集(猫脸码客 第192期)

Cyclone Wildfire Flood Earthquake Database 在自然灾害频发的今天&#xff0c;准确、及时地获取并分析相关数据对于灾害预防、预警及响应至关重要。为此&#xff0c;Cyclone Wildfire Flood Earthquake Database&#xff08;以下简称CWFE Database&#xff09;应运而生&…

计算机毕业设计 农场投入品运营管理系统 Java+SpringBoot+Vue 前后端分离 文档报告 代码讲解 安装调试

&#x1f34a;作者&#xff1a;计算机编程-吉哥 &#x1f34a;简介&#xff1a;专业从事JavaWeb程序开发&#xff0c;微信小程序开发&#xff0c;定制化项目、 源码、代码讲解、文档撰写、ppt制作。做自己喜欢的事&#xff0c;生活就是快乐的。 &#x1f34a;心愿&#xff1a;点…

gcc升级(含命令行升级、手动升级两种方式)

gcc升级 1.yum源替换1.1 备份原始repo配置文件1.2 重新配置CentOS-Base.reporepo文件1.3 清除缓存并重新创建 2. gcc安装3.命令行升级gcc4.手动升级4.1 安装包下载4.2 解压4.3 gcc升级4.3.1 依赖拉取4.3.2 gmp安装4.3.3 mpfr安装4.3.4 mpc安装4.3.5 gcc编译、安装 4.4 gcc命令配…

Linux环境变量进程地址空间

目录 一、初步认识环境变量 1.1常见的环境变量 1.2环境变量的基本概念 二、命令行参数 2.1通过命令行参数获取环境变量 2.2本地变量和内建命令 2.3环境变量的获取 三、进程地址空间 3.1进程&#xff08;虚拟&#xff09;地址空间的引入 3.2进程地址空间的布局和理解 …

简易CPU设计入门:本CPU项目的指令格式

在这一节里面&#xff0c;主要是理论知识&#xff0c;基本上不讲代码。不过&#xff0c;本项目的代码包&#xff0c;大家还是需要下载的。 本项目的代码包的下载方法&#xff0c;参考下面的链接所指示的文章。 下载本项目代码 本节&#xff0c;其实是要讲本项目CPU的指令集。…

大模型蒸馏技术

一篇题为《The Mamba in the Llama: Distilling and Accelerating Hybrid Models》的论文证明&#xff1a;通过重用注意力层的权重&#xff0c;大型 transformer 可以被蒸馏成大型混合线性 RNN&#xff0c;只需最少的额外计算&#xff0c;同时可保留其大部分生成质量。 先来说…

Python学习——【2.1】if语句相关语法

文章目录 【2.1】if语句相关一、布尔类型和比较运算符&#xff08;一&#xff09;布尔类型&#xff08;二&#xff09;比较运算符 二、if语句的基本格式※、练习 三、if-else组合判断语句※、练习 四、if-elif-else多条件判断语句※、练习 五、判断语句的嵌套※、实战案例 【2.…

AlexNet项目图片分类通用模型代码

目录 一&#xff1a;建立AlexNet模型&#xff08;在model文件中写&#xff09; 1.构造5层卷积层 2.构造3层神经网络层 3.forward函数 4.模型最终代码 二&#xff1a;训练数据&#xff08;在train中写&#xff09; 1.读出数据 2.训练 3. 测试模型更新参数 4.完整的训练…

Datawhile 组队学习Tiny-universe Task01

Task01&#xff1a;LLama3模型讲解 仓库链接&#xff1a;GitHub - datawhalechina/tiny-universe: 《大模型白盒子构建指南》&#xff1a;一个全手搓的Tiny-Universe 参考博客&#xff1a;LLaMA的解读与其微调(含LLaMA 2)&#xff1a;Alpaca-LoRA/Vicuna/BELLE/中文LLaMA/姜子…

新的突破,如何让AI与人类对话变得“顺滑”:Moshi背后的黑科技

你有没有想过,当我们跟智能音箱、客服机器人或者语音助手对话时,它们是怎么“听懂”我们说的话,又是怎么迅速给出回应的?就好像你对着Siri、Alexa说一句:“给我订个披萨”,它立刻明白你想要干嘛,然后帮你下单。背后的技术其实比我们想象的要复杂得多,但现在,有了Moshi…