ReUseX
0.0.5
3D Point Cloud Processing for Building Reuse
Loading...
Searching...
No Matches
annotate.hpp
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: 2025 Povl Filip Sonne-Frederiksen
2
//
3
// SPDX-License-Identifier: GPL-3.0-or-later
4
5
#pragma once
6
#include "
../global-params.hpp
"
7
8
#include <CLI/CLI.hpp>
9
#include <filesystem>
10
#include <memory>
11
#include <string>
12
13
namespace
fs = std::filesystem;
14
15
struct
SubcommandAnnotateOptions
{
16
17
fs::path
net_path
= fs::current_path() /
"yolov8x-seg.torchscript"
;
18
19
bool
isCuda
{
false
};
20
21
// Dataloader configuration
22
size_t
batch_size
= 16;
// Batch size for inference (recommended: 8-64)
23
bool
shuffle
=
false
;
// Shuffle dataset (rarely needed for inference)
24
size_t
num_workers
= 4;
// Number of worker threads (recommended: 2-4)
25
size_t
prefetch_batches
= 8;
// Batches to prefetch (recommended: 2-3x workers)
26
};
27
28
// Function declarations.
29
void
setup_subcommand_create_annotate
(CLI::App &app, std::shared_ptr<RuxOptions> global_opt);
30
int
run_subcommand_annotate
(
SubcommandAnnotateOptions
const
&opt,
const
RuxOptions
&global_opt);
setup_subcommand_create_annotate
void setup_subcommand_create_annotate(CLI::App &app, std::shared_ptr< RuxOptions > global_opt)
run_subcommand_annotate
int run_subcommand_annotate(SubcommandAnnotateOptions const &opt, const RuxOptions &global_opt)
global-params.hpp
RuxOptions
Definition
global-params.hpp:44
SubcommandAnnotateOptions
Definition
annotate.hpp:15
SubcommandAnnotateOptions::net_path
fs::path net_path
Definition
annotate.hpp:17
SubcommandAnnotateOptions::num_workers
size_t num_workers
Definition
annotate.hpp:24
SubcommandAnnotateOptions::prefetch_batches
size_t prefetch_batches
Definition
annotate.hpp:25
SubcommandAnnotateOptions::batch_size
size_t batch_size
Definition
annotate.hpp:22
SubcommandAnnotateOptions::shuffle
bool shuffle
Definition
annotate.hpp:23
SubcommandAnnotateOptions::isCuda
bool isCuda
Definition
annotate.hpp:19
apps
rux
include
create
annotate.hpp
Generated by
1.16.1