HTML实现 扫雷游戏

前言:

游戏起源与发展

  • 扫雷游戏的雏形可追溯到 1973 年的 “方块(cube)” 游戏,后经改编出现了 “rlogic” 游戏,玩家需为指挥中心探出安全路线避开地雷。在此基础上,开发者汤姆・安德森编写出了扫雷游戏的雏形.

  • 1992 年,微软在 windows3.1 系统中首次预装了《扫雷》,将其作为训练用户鼠标操作能力的软件.

  • 虽从 windows8 开始,系统不再默认安装扫雷游戏,但它依旧凭借自身魅力受到众多玩家喜爱,甚至有玩家不断刷新时间记录来挑战自我.

游戏规则

  • 胜利条件:找出所有地雷且不踩到地雷,或者在规定时间内尽可能多地找出地雷.

  • 失败条件:翻开了埋有地雷的方块.

  • 基础操作:左键点击未打开的格子可将其打开;右键点击可标雷 / 取消标雷;双击(左右键同时点击)已打开的数字,若该数字周围标的雷数量等于该数字,会同时打开该数字周围剩余所有格子.

游戏界面及信息

  • 剩余雷数:显示在游戏界面左上角,为总雷数减去已标雷数,可据此了解雷区剩余雷的大致情况.

  • 计时器:位于右上角,从本局游戏第一次操作为 0.001 秒开始计时,可用于记录游戏所用时间及玩家挑战自我时作为参考

技巧与策略

  • 数字推理:数字代表其周围 8 个方格中的雷数,若数字为 0,游戏会自动打开周围所有格子;若一个方格周围已标记的雷数等于该方格上的数字,那么其周围未标记的方格都可安全打开.

  • 常见阵型判断:如 “111”“22”“112” 等常见数字组合,可依据特定规律快速判断雷的位置.

  • 边缘优先:可先从雷区边缘开始点击,因为边缘方格的周围方格数量相对较少,更容易判断雷的位置,降低推理难度7.

  • 标记问号:当无法确定方格是否有雷时,可右键点击两次标记问号,后续再根据其他信息进一步判断.

游戏变化与创新

  • 在线多人模式:如《一起来扫雷》,玩家可与世界各地的玩家合作或竞争,共同清除地图上的地雷,还能积累积分兑换装饰,装扮游戏界面.

  • VR 版扫雷:扫雷 VR 将平面的扫雷游戏搬到了 3D 场景中,增加了游戏的趣味性和沉浸感.

  • 融合其他元素:《扫雷俄罗斯方块》结合了扫雷和俄罗斯方块的元素,雷区不断向上生长,找到所有地雷时行才会被清除

以上内容由ai生成

正文:
1.自己实现一个扫雷游戏

2.使用HTML实现

<!DOCTYPE html>
<html lang="en"><head><meta charset="UTF-8" /><title>扫雷游戏</title><linkhref="https://fonts.googleapis.com/css?family=Space+Mono:400,700"rel="stylesheet"/><linkrel="stylesheet"href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"/><style>@charset "UTF-8";*,*:before,*:after {box-sizing: inherit;}html {box-sizing: border-box;}body {text-align: center;color: #333;padding: 20px 20px 100px;background-color: #efefef;font-family: 'Space Mono', monospace;}h1 {margin: 0 0 32px;}p {font-size: 1em;line-height: 1.25em;}a {color: inherit;}img {height: auto;max-width: 100%;}.wrap {text-align: center;position: relative;display: inline-block;}.legend {font-size: 14px;margin: 0 auto 32px;}.legend h4,.legend p {margin: 0 0 6px;}.legend code {background: #e3e3e3;}.legend code .key {color: #ec433c;}.legend code .click {color: #2a48ec;}.top {border: 6px solid #e3e3e3;background-color: #e3e3e3;}#scoreboard {display: flex;padding-bottom: 12px;justify-content: space-between;}#scoreboard .select-wrap {font-weight: 700;vertical-align: top;display: inline-block;}#scoreboard .select-wrap select {margin: 0;height: 36px;border-radius: 0;border-width: 3px;border-style: solid;background-color: #d1d1d1;border-color: white #9e9e9e #9e9e9e white;}#scoreboard .select-wrap select:hover,#scoreboard .select-wrap select:focus {backgroudn-color: #ebebeb;}#scoreboard .reset {padding: 0 4px;font-size: 24px;cursor: pointer;font-weight: 700;line-height: 30px;border-width: 3px;border-style: solid;background-color: #d1d1d1;border-color: white #9e9e9e #9e9e9e white;}#scoreboard .reset:hover,#scoreboard .reset:focus {outline: none;background-color: #ebebeb;}#scoreboard .counter {padding: 0 4px;color: #ec433c;border: 3px inset;line-height: 30px;letter-spacing: 0.08em;display: inline-block;background: #333;text-shadow: 0 0 2px #ec433c;}#scoreboard .counter:first-of-type {margin-right: 20px;}#scoreboard .counter:last-of-type {margin-left: 20px;}#grid {margin: 0 auto;position: relative;display: inline-block;}#grid ::-moz-selection {background-color: transparent;}#grid ::selection {background-color: transparent;}#grid.disabled .cell {pointer-events: none;}#grid.disabled .status-indicator {top: 50%;left: 50%;z-index: 11;width: 8vw;height: 8vw;font-size: 4vw;cursor: pointer;line-height: 8vw;position: absolute;border-radius: 50%;pointer-events: auto;background-color: #d1d1d1;transform: translate(-50%, -50%);border: 1px solid rgba(51, 51, 51, 0.25);}#grid.disabled .status-indicator::after {content: '';}#grid.disabled.win .status-indicator::after {content: '😎';}#grid.disabled.lose .status-indicator::after {content: '☹️';}#grid .row {display: flex;}#grid .cell {cursor: pointer;width: 24px;height: 24px;position: relative;background-color: #d1d1d1;border-width: 3px;border-style: solid;border-color: white #9e9e9e #9e9e9e white;}#grid .cell i {left: 0;bottom: 0;margin: 0;width: 100%;font-size: 14px;font-weight: 700;font-style: normal;position: absolute;line-height: 24px;}#grid .cell::before {top: 0;left: 0;right: 0;bottom: 0;z-index: 1;content: '';position: absolute;background-color: #d1d1d1;}#grid .cell::after {top: 50%;left: 50%;content: '';position: absolute;transform: translate(-50%, -50%);}#grid .cell:hover::before {background-color: #ebebeb;}#grid .cell.revealed {border: 1px solid #b8b8b8;}#grid .cell.revealed::before {display: none;}#grid .cell.revealed .flag {display: none;}#grid .cell .flag {top: 50%;left: 50%;z-index: 1;width: 10px;height: 4px;position: absolute;border-style: solid;border-width: 4px 0 4px 10px;transform: translate(-50%, -50%);border-color: transparent transparent transparent #ec433c;}#grid .cell.maybe .flag {border-color: transparent transparent transparent #d7af42;}#grid .cell.mine {background-color: #ec433c;}#grid .cell.mine::after {border-radius: 50%;width: 12px;height: 12px;background-color: #333;}#grid .cell.incorrect .flag::before,#grid .cell.incorrect .flag::after {top: 50%;z-index: 1;left: -13px;height: 2px;width: 16px;content: '';position: absolute;background-color: black;}#grid .cell.incorrect .flag::before {transform: rotate(-45deg);}#grid .cell.incorrect .flag::after {transform: rotate(45deg);}#grid .cell.mousedown {border: none;}#leaderboard {margin-top: 20px;text-align: center;}#leaderboard h4 {margin: 0 0 10px;}#leaderboard ul {margin: 0;padding: 10px;display: inline-block;background-color: rgba(209, 209, 209, 0.5);}#leaderboard ul li {padding: 2px;list-style: none;}#leaderboard ul li span {font-weight: 900;text-transform: capitalize;}#leaderboard ul li.highlight {background-color: #fef178;}#leaderboard button {border: none;outline: none;cursor: pointer;font-size: 12px;font-weight: 700;-webkit-appearance: none;-moz-appearance: none;appearance: none;background: none;text-decoration: underline;}.cell.white {color: #fff;}.cell.gray-light {color: #efefef;}.cell.gray-mid {color: #e3e3e3;}.cell.gray {color: #d1d1d1;}.cell.gray-dark {color: #808080;}.cell.black {color: #333;}.cell.red {color: #ec433c;}.cell.maroon {color: #a6070f;}.cell.purple {color: #a42887;}.cell.yellow {color: #d7af42;}.cell.yellow-light {color: #fef178;}.cell.blue {color: #2a48ec;}.cell.blue-dark {color: #233db7;}.cell.green {color: #2bb13d;}.cell.turquoise {color: #28907d;}#devbox {top: 10px;right: 10px;position: fixed;text-align: left;max-width: 300px;color: #fff;background-color: #333;}#devbox p {margin: 0;font-size: 12px;padding: 10px 20px;}#devbox p + p {padding-top: 5px;}</style></head><body><header class="site-header" role="banner"><div class="wrap"><h1>扫雷</h1><div class="legend"><p><strong>插旗:</strong><code><span class="key">alt</span>+<span class="click">click(单击)</span></code></p></div></div></header><main class="site-main" role="main"><div class="wrap"><div id="board"><div class="top"><div id="scoreboard"><div id="minecounter" class="counter"></div><div><div class="select-wrap"><select name="level" id="level"><option value="beginner">初级</option><option value="intermediate">中级</option><option value="expert" selected>高级</option></select></div><button class="reset">🙂</button></div><div id="timer" class="counter"></div></div><div id="grid"></div></div><div class="bottom"></div></div></div></main><script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script><script>$(document).ready(function () {var $body, $document, $board, $grid, timer, time, unstarted;function _init() {// Cache some common DOM queries$document = $(document);$body = $('body');$body.addClass('loaded');// Start Minesweeper$board = $('#board');$grid = $('#grid');var $timer = $('#timer');var $mineCounter = $('#minecounter');var $levelSelect = $('#level');var levels = {beginner: '9x9x10',intermediate: '16x16x44',expert: '16x30x99',};var level = $levelSelect.val();var levelParams,rows,$rows,columns,cellCount,mines,freeCells,mineTally,pauseTime,beginnerHighScore = 999,intermediateHighScore = 999,expertHighScore = 999;var countColors = {0: '',1: 'blue',2: 'green',3: 'red',4: 'blue-dark',5: 'maroon',6: 'turquoise',7: 'purple',8: 'gray-dark',};time = 0;timer = false;unstarted = true;var statusIndicator = '<div class="status-indicator"></div>';// Check for existing high score// if (localStorage.getItem('beginner')) {//   beginnerHighScore = localStorage.getItem('beginner');//   populateHighScore('beginner', localStorage.getItem('beginner'));// }// if (localStorage.getItem('intermediate')) {//   intermediateHighScore = localStorage.getItem('intermediate');//   populateHighScore('intermediate', localStorage.getItem('intermediate'));// }// if (localStorage.getItem('expert')) {//   expertHighScore = localStorage.getItem('expert');//   populateHighScore('expert', localStorage.getItem('expert'));// }function setLevel(level) {levelParams = levels[level];rows = parseInt(levelParams.split('x')[0]);columns = parseInt(levelParams.split('x')[1]);cellCount = rows * columns;mines = levelParams.split('x')[2];freeCells = cellCount - mines;}function setBoard(level) {// Clear Grid$grid.html(statusIndicator).removeClass('disabled lose win').addClass('unstarted');// Set Up GridsetLevel(level);// Set unstartedunstarted = true;// Build Rowsfor (r = 0; r < rows; r++) {var newCells = '';// Build Cellsfor (c = 0; c < columns; c++) {newCells += '<div class="cell"></div>';}$grid.append('<div class="row">' + newCells + '</div>');}// Set MinecountermineTally = mines;$mineCounter.html(mineTally);// Set TimerresetTimer();}// Set initiallysetBoard(level);// Set on reset$('html').on('mousedown', '.reset', function () {$(this).text('😮');}).on('mouseup', '.reset', function () {$(this).text('🙂');stopTimer();level = $levelSelect.val();setBoard(level);});// Set when clicking status indicator$('html').on('click', '.status-indicator', function () {level = $levelSelect.val();setBoard(level);});// Set on level change$levelSelect.on('change', function () {stopTimer();resetTimer();level = $levelSelect.val();setBoard(level);});// Lay Minesfunction layMines(level, clickedCellIndex) {$rows = $('.row');var freeCells = $('.cell');var takenCells = [clickedCellIndex];// Lay Minesfor (m = 0; m < mines; m++) {var mineCell = Math.floor(Math.random() * Math.floor(freeCells.length));// If it happens to be the clicked cell, skip itif ($.inArray(mineCell, takenCells) > -1) {m--;continue;}takenCells.push(mineCell);$(freeCells[mineCell]).addClass('mine');}// Identify Cell Numbersvar $cells = $('.cell');for (c = 0; c < $cells.length; c++) {var $cell = $($cells[c]);$cell.attr('data-cell', c);// Skip if it's a mineif ($cell.is('.mine')) {continue;}var mineCount = 0;var rowPos = Math.floor(c / columns);var $currentRow = $cell.closest('.row');$currentRow.attr('data-row', rowPos);var rowCells = $currentRow.find('.cell');var cellPos = c % columns;if ($(rowCells[cellPos - 1]).is('.mine')) {mineCount++;}if ($(rowCells[cellPos + 1]).is('.mine')) {mineCount++;}if (rowPos > 0) {var prevRowCells = $($rows[rowPos - 1]).find('.cell');if ($(prevRowCells[cellPos - 1]).is('.mine')) {mineCount++;}if ($(prevRowCells[cellPos]).is('.mine')) {mineCount++;}if ($(prevRowCells[cellPos + 1]).is('.mine')) {mineCount++;}}if (rowPos < rows - 1) {var nextRowCells = $($rows[rowPos + 1]).find('.cell');if ($(nextRowCells[cellPos - 1]).is('.mine')) {mineCount++;}if ($(nextRowCells[cellPos]).is('.mine')) {mineCount++;}if ($(nextRowCells[cellPos + 1]).is('.mine')) {mineCount++;}}if (mineCount > 0) {$cell.html('<i>' + mineCount + '</i>');// Styling classesvar colorClass = countColors[mineCount];$cell.addClass(colorClass);} else {$cell.addClass('zero');}}}// Click cell to start game$('html').off('click', '#grid.unstarted .cell').on('click', '#grid.unstarted .cell', function (e) {$grid.removeClass('unstarted');if (unstarted && !$(e.target).is('.mine')) {layMines(level, $('.cell').index(this));timer = window.setInterval(startTimer, 1000);unstarted = false;}});// Timer Functionsfunction resetTimer() {$timer.html('000');time = 0;}function startTimer() {time++;if (time < 10) {$timer.html('00' + time);} else if (time > 9 && time < 100) {$timer.html('0' + time);} else {$timer.html(time);}}function stopTimer() {window.clearInterval(timer);}function pauseTimer() {stopTimer();pauseTime = parseInt($('#timer').html());}function unpauseTimer() {time = pauseTime;timer = window.setInterval(startTimer, 1000);pauseTime = false;}// Pause when window loses focus$(window).on('blur', function () {pauseTimer();}).on('focus', function () {if (pauseTime) {unpauseTimer();}});// Check Cellfunction checkCell($cell) {if (!$cell.is('.mine') && !$cell.is('.revealed')) {cellClick($cell, 'reveal');if ($cell.is('.zero')) {$cell.trigger('click');}}}// Clicking on a cellfunction cellClick($cell, action) {// If Flaggingif (action === 'flag' && !$cell.is('.revealed')) {if ($cell.is('.flagged')) {$cell.removeClass('flagged');$cell.addClass('maybe');mineTally++;updateMinecounter(mineTally);} else if ($cell.is('.maybe')) {$cell.removeClass('maybe');var flag = $cell.find('.flag');flag.remove();} else {$cell.addClass('flagged');$cell.append('<span class="flag"></span>');mineTally--;updateMinecounter(mineTally);}// If Revealing} else if (action === 'reveal') {$cell.addClass('revealed');// If it's a mine you lose!if ($cell.is('.mine')) {lose();}statusCheck();} else if (action === 'clear') {if (!$cell.is('.revealed') || $cell.is('.zero')) {return;}clearClick($cell);}}// Update Minecounterfunction updateMinecounter(mineTally) {if (mineTally < 10) {$mineCounter.html('0' + mineTally);} else {$mineCounter.html(mineTally);}}// Clicking on a Zero cellfunction zeroClick($cell) {var cellPos = $cell.prevAll().length;var $currentRow = $cell.closest('.row');var rowPos = parseInt($currentRow.attr('data-row'));var rowCells = $currentRow.find('.cell');checkCell($(rowCells[cellPos - 1]));checkCell($(rowCells[cellPos + 1]));if (rowPos > 0) {var prevRowCells = $($rows[rowPos - 1]).find('.cell');checkCell($(prevRowCells[cellPos - 1]));checkCell($(prevRowCells[cellPos]));checkCell($(prevRowCells[cellPos + 1]));}if (rowPos < rows) {var nextRowCells = $($rows[rowPos + 1]).find('.cell');checkCell($(nextRowCells[cellPos - 1]));checkCell($(nextRowCells[cellPos]));checkCell($(nextRowCells[cellPos + 1]));}}// Clicking on a number to clear free cellsfunction clearClick($cell) {var cellPos = $cell.prevAll().length;var $currentRow = $cell.closest('.row');var rowPos = parseInt($currentRow.attr('data-row'));var rowCells = $currentRow.find('.cell');var adjacentCells = [];var correctClear = true;var adjacentMines = 0;var adjacentFlags = 0;var i;adjacentCells.push($(rowCells[cellPos - 1]));adjacentCells.push($(rowCells[cellPos + 1]));if (rowPos > 0) {var prevRowCells = $($rows[rowPos - 1]).find('.cell');adjacentCells.push($(prevRowCells[cellPos - 1]));adjacentCells.push($(prevRowCells[cellPos]));adjacentCells.push($(prevRowCells[cellPos + 1]));}if (rowPos < rows) {var nextRowCells = $($rows[rowPos + 1]).find('.cell');adjacentCells.push($(nextRowCells[cellPos - 1]));adjacentCells.push($(nextRowCells[cellPos]));adjacentCells.push($(nextRowCells[cellPos + 1]));}for (i = 0; i < adjacentCells.length; i++) {// add to mine countif ($(adjacentCells[i]).is('.mine')) {adjacentMines++;}// add to flag coutif ($(adjacentCells[i]).is('.flagged')) {adjacentFlags++;}}if (adjacentFlags === adjacentMines) {for (i = 0; i < adjacentCells.length; i++) {if ($(adjacentCells[i]).is('.mine')) {if ($(adjacentCells[i]).is('.flagged')) {continue;} else {$(adjacentCells[i]).addClass('revealed');correctClear = false;}} else if ($(adjacentCells[i]).is('.flagged')) {correctClear = false;$(adjacentCells[i]).addClass('incorrect');lose();}}if (correctClear) {for (i = 0; i < adjacentCells.length; i++) {if (!$(adjacentCells[i]).is('.mine')) {if ($(adjacentCells[i]).is('.zero')) {zeroClick($(adjacentCells[i]));}cellClick($(adjacentCells[i]), 'reveal');}}}} else {return;}}// Check statusfunction statusCheck() {if ($('.cell.revealed').length == freeCells) {stopTimer();var winTime = $('#timer').html();$grid.addClass('disabled win');resetHighScore(level, winTime);}}function lose() {$grid.addClass('disabled lose');stopTimer();}// Clicking on a cell$('html').on('click', '.cell', function (e) {e.preventDefault();var action = 'reveal';var $cell = $(this);if (e.altKey || e.which === 3) {action = 'flag';} else if ($cell.is('.revealed') ||(e.which === 1) & (e.which === 3)) {action = 'clear';}if ($cell.is('.flagged') && !e.altKey) {return;}if ($cell.is('.zero')) {zeroClick($cell);}cellClick($cell, action);});// Mouse down on a cell$('html').on('mousedown', '.cell:not(.revealed,.flagged)', function (e) {if (!e.altKey && e.which !== 3) {$(this).addClass('mousedown');}}).on('mouseup mouseleave', '.cell.mousedown', function () {$(this).removeClass('mousedown');});// Scoreboard functionalityfunction resetHighScore(level, winTime) {if (localStorage.getItem(level)) {if (winTime < localStorage.getItem(level)) {localStorage.setItem(level, winTime);populateHighScore(level, winTime, true);}} else {localStorage.setItem(level, winTime);populateHighScore(level, winTime, true);}}function populateHighScore(level, highScore, highlight) {if (!$('#leaderboard').length) {$board.find('.bottom').append('<div id="leaderboard"><h4>High Scores</h4><ul><li class="beginner"></li><li class="intermediate"></li><li class="expert"></li></ul><div><button id="score-reset" class="score-reset">Clear Scores</button></div></div>');}if (highlight === true) {$('#leaderboard .highlight:not(.' + level + ')').removeClass('highlight');$('#leaderboard .' + level).addClass('highlight');}var highScoreDisplay = parseInt(highScore, 10);$('#leaderboard .' + level).html('<span>' + level + '</span>: ' + highScoreDisplay + ' seconds');}function clearScores() {localStorage.clear();$('#leaderboard').remove();}// Clicking on score reset to clear scores$('html').on('click', '#score-reset', clearScores);}_init();});</script></body>
</html>

3.电脑单机就可玩耍

最后:

你今天扫雷了吗?后台回复“扫雷”获取在线连接。
扫雷游戏

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

如若内容造成侵权/违法违规/事实不符,请联系长河编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

docker镜像源配置、换源、dockerhub国内镜像最新可用加速源(仓库)

一、临时拉取方式 在docker pull后先拼接镜像源域名&#xff0c;后面拼接拉取的镜像名 $ docker pull dockerpull.org/continuumio/miniconda3 二、永久配置方式 vim修改/etc/docker/daemon.json&#xff0c;并重启docker服务。 # 创建目录 sudo mkdir -p /etc/docker# 写…

AMD(Xilinx) FPGA配置Flash大小选择

目录 1 FPGA配置Flash大小的决定因素2 为什么选择的Flash容量大小为最小保证能够完成整个FPGA的配置呢&#xff1f; 1 FPGA配置Flash大小的决定因素 在进行FPGA硬件设计时&#xff0c;选择合适的配置Flash是我们进行硬件设计必须考虑的&#xff0c;那么配置Flash大小的选择由什…

NVR录像机汇聚管理EasyNVR多品牌NVR管理工具/设备如何使用Docker运行?

在当今的安防监控领域&#xff0c;随着视频监控技术的不断发展和应用范围的扩大&#xff0c;如何高效、稳定地管理并分发视频流资源成为了行业内外关注的焦点。EasyNVR作为一款功能强大的多品牌NVR管理工具/设备&#xff0c;凭借其灵活的部署方式和卓越的性能&#xff0c;正在引…

【SKFramework框架】一、框架介绍

推荐阅读 CSDN主页GitHub开源地址Unity3D插件分享QQ群&#xff1a;398291828小红书小破站 大家好&#xff0c;我是佛系工程师☆恬静的小魔龙☆&#xff0c;不定时更新Unity开发技巧&#xff0c;觉得有用记得一键三连哦。 一、前言 【Unity3D框架】SKFramework框架完全教程《全…

Python 版本的 2024详细代码

2048游戏的Python实现 概述&#xff1a; 2048是一款流行的单人益智游戏&#xff0c;玩家通过滑动数字瓷砖来合并相同的数字&#xff0c;目标是合成2048这个数字。本文将介绍如何使用Python和Pygame库实现2048游戏的基本功能&#xff0c;包括游戏逻辑、界面绘制和用户交互。 主…

排序算法(选择排序、直接插入排序、冒泡排序、二路归并排序)(C语言版)

对数组进行排序&#xff0c;主要演示选择排序、直接排序、冒泡排序、二路归并排序算法&#xff0c;附上代码演示 一、编写好各类排序方法的函数 &#xff08;1&#xff09; s_sort(int e[],int n):选择排序。 &#xff08;2&#xff09;si_sort(int e[],int n):直接插人排序。…

Unity图形学之Surface Shader结构

1.没有Pass&#xff1a;因为Render Path已经封装好了 Shader "Custom/Test" {Properties{_Color ("Color", Color) (1,1,1,1)_MainTex ("Albedo (RGB)", 2D) "white" {}_Glossiness ("Smoothness", Range(0,1)) 0.5_Meta…

数据集-目标检测系列- 牵牛花 检测数据集 morning_glory >> DataBall

数据集-目标检测系列- 牵牛花 检测数据集 morning DataBall 助力快速掌握数据集的信息和使用方式&#xff0c;会员享有 百种数据集&#xff0c;持续增加中。 贵在坚持&#xff01; 数据样例项目地址&#xff1a; * 相关项目 1&#xff09;数据集可视化项目&#xff1a;git…

摄影:相机控色

摄影&#xff1a;相机控色 白平衡&#xff08;White Balance&#xff09;白平衡的作用&#xff1a; 白平衡的使用环境色温下相机色温下总结 白平衡偏移与包围白平衡包围 影调 白平衡&#xff08;White Balance&#xff09; 人眼看到的白色&#xff1a;会自动适应环境光线。 相…

Odoo :免费且开源的农牧行业ERP管理系统

文 / 开源智造Odoo亚太金牌服务 引言 提供农牧企业数字化、智能化、无人化产品服务及全产业链高度协同的一体化解决方案&#xff0c;提升企业智慧种养、成本领先、产业互联的核心竞争力。 行业典型痛点 一、成本管理粗放&#xff0c;效率低、管控弱 产品研发过程缺少体系化…

oracle查看锁阻塞-谁阻塞了谁

一 模拟锁阻塞 #阻塞1 一个会话正在往一个大表写入大量数据的时候&#xff0c;另一个会话加字段&#xff1a; #会话1 #会话2 会话2被阻塞了。 #阻塞2 模拟一个会话update一条记录&#xff0c;没提交。 另一个会话也update这一条记录&#xff1a; 会话2被阻塞了。 二 简单查…

HDR视频技术之三:色度学与颜色空间

HDR 技术的第二个理论基础是色度学。从前面的内容中可以了解到&#xff0c;光学以及人类视觉感知模型为人类提供了解释与分析人类感知亮度的理论基础&#xff0c;但是 HDR 技术不仅仅关注于提升图像与视频的亮度范围&#xff0c;同时也关注于提供更加丰富的色彩。因此&#xff…

神经网络中常用的激活函数(公式 + 函数图像)

激活函数是人工神经网络中的一个关键组件&#xff0c;负责引入非线性&#xff0c;从而使神经网络能够学习和表示复杂的非线性关系。没有激活函数&#xff0c;神经网络中的所有计算都是线性变换&#xff0c;而线性模型的表达能力有限&#xff0c;无法处理复杂的任务。 激活函数…

Redis——Raft算法

Raft使用较为广泛的强一致性、去中心化、高可用的分布式协议&#xff0c;即使在网络、节点故障等情况下&#xff0c;多个节点依然能达到一致性。 其中redis、etcd等都用到了这种算法 在Redis集群中&#xff0c;采取的主从复制结构&#xff0c;当主节点宕机后&#xff0c;哨兵会…

C 语言复习总结记录二

C 语言复习总结记录二 一 控制语句 1、语句的分类 表达式语句函数调用语句复合语句控制语句空语句 控制语句 控制程序的执行流程&#xff0c;实现程序的各种结构方式 C 语言支持三种结构 &#xff1a;顺序结构、选择结构、循环结构&#xff0c;由特定的语句定义符组成C语言…

网络无人值守批量装机-cobbler

网络无人值守批量装机-cobbler 一、cobbler简介 ​ 上一节中的pxe+kickstart已经可以解决网络批量装机的问题了,但是环境配置过于复杂,而且仅针对某一个版本的操作系统进批量安装则无法满足目前复杂环境的部署需求。 ​ 本小节所讲的cobbler则是基于pxe+kickstart技术的二…

基于深度学习CNN算法的花卉分类识别系统01--带数据集-pyqt5UI界面-全套源码

文章目录 基于深度学习算法的花卉分类识别系统一、项目摘要二、项目运行效果三、项目文件介绍四、项目环境配置1、项目环境库2、环境配置视频教程 五、项目系统架构六、项目构建流程1、数据集2、算法网络Mobilenet3、网络模型训练4、训练好的模型预测5、UI界面设计-pyqt56、项目…

HarmonyOs鸿蒙开发实战(20)=>一文学会基础使用组件导航Navigation

敲黑板&#xff0c;以下是重点技巧。文章末尾有实战项目效果截图及代码截图可参考 1.概要 Navigation是路由导航的根视图容器Navigation组件主要包含​导航页&#xff08;NavBar&#xff09;和子页&#xff08;NavDestination&#xff09;&#xff0c;导航页不存在页面栈中&am…

tcpdump抓包 wireShark

TCPdump抓包工具介绍 TCPdump&#xff0c;全称dump the traffic on anetwork&#xff0c;是一个运行在linux平台可以根据使用者需求对网络上传输的数据包进行捕获的抓包工具。 tcpdump可以支持的功能: 1、在Linux平台将网络中传输的数据包全部捕获过来进行分析 2、支持网络层…

已阻止加载“http://localhost:8086/xxx.js”的模块,它使用了不允许的 MIME 类型 (“text/plain”)。

记录今天解决的一个小bug 在终端启动8080端口号监听后&#xff0c;打开网址http://localhost:8080&#xff0c;发现不能正确加载页面&#xff0c;打开检查-控制台&#xff0c;出现如下警告&#xff1a;已阻止加载“http://localhost:8086/xxx.js”的模块&#xff0c;它使用了不…