pref: 删除标注页面信息栏, 减小摄像头采集分辨率
This commit is contained in:
@@ -82,10 +82,10 @@ def capture_thread():
|
|||||||
cam_right = cv2.VideoCapture('/dev/videoR')
|
cam_right = cv2.VideoCapture('/dev/videoR')
|
||||||
|
|
||||||
# # 设置摄像头分辨率
|
# # 设置摄像头分辨率
|
||||||
cam_left.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)
|
cam_left.set(cv2.CAP_PROP_FRAME_WIDTH, 640)
|
||||||
cam_left.set(cv2.CAP_PROP_FRAME_HEIGHT, 720)
|
cam_left.set(cv2.CAP_PROP_FRAME_HEIGHT, 480)
|
||||||
cam_right.set(cv2.CAP_PROP_FRAME_WIDTH, 1280)
|
cam_right.set(cv2.CAP_PROP_FRAME_WIDTH, 640)
|
||||||
cam_right.set(cv2.CAP_PROP_FRAME_HEIGHT, 720)
|
cam_right.set(cv2.CAP_PROP_FRAME_HEIGHT, 480)
|
||||||
|
|
||||||
while True:
|
while True:
|
||||||
ret_left, frame_left = cam_left.read()
|
ret_left, frame_left = cam_left.read()
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>人工标注</title>
|
<title>Mark</title>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/fabric.js/5.3.1/fabric.min.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/fabric.js/5.3.1/fabric.min.js"></script>
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
@@ -178,16 +178,16 @@
|
|||||||
<body>
|
<body>
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<h1>人工标注</h1>
|
<h1>ReMark</h1>
|
||||||
<a href="/list" class="btn-secondary">返回图片列表</a>
|
<a href="/list" class="btn-secondary">返回图片列表</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="info-panel">
|
<!-- <div class="info-panel">
|
||||||
<h3>图像信息</h3>
|
<h3>图像信息</h3>
|
||||||
<p><strong>图像 ID:</strong> <span id="image-id"></span></p>
|
<p><strong>图像 ID:</strong> <span id="image-id"></span></p>
|
||||||
<p><strong>时间戳:</strong> <span id="image-timestamp"></span></p>
|
<p><strong>时间戳:</strong> <span id="image-timestamp"></span></p>
|
||||||
<p><strong>备注:</strong> <span id="image-comment"></span></p>
|
<p><strong>备注:</strong> <span id="image-comment"></span></p>
|
||||||
</div>
|
</div> -->
|
||||||
|
|
||||||
<!-- <div class="instructions">
|
<!-- <div class="instructions">
|
||||||
<h3>操作说明</h3>
|
<h3>操作说明</h3>
|
||||||
@@ -216,8 +216,8 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="status">
|
<div class="status">
|
||||||
<p>当前状态: <span id="status-text">请选择一个目标类别开始标注</span></p>
|
<p>当前状态:<span id="status-text">请选择一个目标类别开始标注</span></p>
|
||||||
<p>当前选中类别: <span id="selected-label">无</span></p>
|
<p>当前选中类别:<span id="selected-label">无</span></p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<button class="btn-primary" id="save-btn">保存标注结果</button>
|
<button class="btn-primary" id="save-btn">保存标注结果</button>
|
||||||
@@ -480,8 +480,8 @@
|
|||||||
: `/static/received/right/${image.right_filename}`;
|
: `/static/received/right/${image.right_filename}`;
|
||||||
|
|
||||||
const imageInfo = side === 'left'
|
const imageInfo = side === 'left'
|
||||||
? `左摄像头图像: ${image.left_filename}`
|
? `左摄像头图像:${image.left_filename}`
|
||||||
: `右摄像头图像: ${image.right_filename}`;
|
: `右摄像头图像:${image.right_filename}`;
|
||||||
|
|
||||||
// 更新图像信息显示
|
// 更新图像信息显示
|
||||||
document.querySelector('.info-panel h3').textContent = imageInfo;
|
document.querySelector('.info-panel h3').textContent = imageInfo;
|
||||||
@@ -513,7 +513,7 @@
|
|||||||
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Error loading image data:', error);
|
console.error('Error loading image data:', error);
|
||||||
alert('加载图像数据失败: ' + error.message);
|
alert('加载图像数据失败:' + error.message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -551,7 +551,7 @@
|
|||||||
item.className = 'detection-item';
|
item.className = 'detection-item';
|
||||||
item.innerHTML = `
|
item.innerHTML = `
|
||||||
<strong>${detection.label} (${detection.categoryId})</strong><br>
|
<strong>${detection.label} (${detection.categoryId})</strong><br>
|
||||||
边界框: [${detection.bbox.join(', ')}]
|
边界框:[${detection.bbox.join(', ')}]
|
||||||
`;
|
`;
|
||||||
container.appendChild(item);
|
container.appendChild(item);
|
||||||
});
|
});
|
||||||
@@ -618,7 +618,7 @@
|
|||||||
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Error saving manual annotations:', error);
|
console.error('Error saving manual annotations:', error);
|
||||||
alert('保存失败: ' + error.message);
|
alert('保存失败:' + error.message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user