Goby3  3.1.5a
2024.05.23
log_tool_config.proto
Go to the documentation of this file.
1 syntax = "proto2";
2 import "goby/middleware/protobuf/app_config.proto";
3 import "goby/protobuf/option_extensions.proto";
4 
5 package goby.apps.middleware.protobuf;
6 
7 message LogToolConfig
8 {
9  optional goby.middleware.protobuf.AppConfig app = 1
10  [(goby.field) = { cfg { action: DEVELOPER } }];
11 
12  required string input_file = 10 [(goby.field) = {
13  description: "Input goby_logger file to read (e.g. 'vehicle_20200204T121314.goby') [can omit --input_file if 1st parameter]"
14  cfg { position: { enable: true }, cli_short: "i" }
15  }];
16 
17  optional string type_regex = 15 [
18  default = ".*",
19  (goby.field) = {
20  description: "Regex that must match type to process this message entry into the output file"
21  cfg { action: ADVANCED }
22  }
23 
24  ];
25  optional string group_regex = 16 [
26  default = ".*",
27  (goby.field) = {
28  description: "Regex that must match group to process this message entry into the output file"
29  cfg { action: ADVANCED }
30  }
31 
32  ];
33  optional string exclude_type_regex = 17 [
34  default = "",
35  (goby.field) = {
36  description: "Regex that if it matches the type excludes processing this message entry into the output file"
37  cfg { action: ADVANCED }
38  }
39 
40  ];
41  optional string exclude_group_regex = 18 [
42  default = "",
43  (goby.field) = {
44  description: "Regex that if it matches the group excludes processing this message entry into the output file"
45  cfg { action: ADVANCED }
46  }
47 
48  ];
49 
50  optional string output_file = 20 [(goby.field) = {
51  description: "Output file to write (default is determined by input_file name "
52  "and output format, e.g. vehicle_20200204T121314.txt for "
53  "DEBUG_TEXT, vehicle_20200204T121314.h5 for HDF5) [can omit --output_file if 2nd parameter]"
54  cfg { position: { enable: true }, cli_short: "o" }
55  }];
56 
57  enum OutputFormat
58  {
59  DEBUG_TEXT = 1;
60  HDF5 = 2;
61  JSON = 3;
62  }
63 
64  optional OutputFormat format = 30 [
65  default = DEBUG_TEXT,
66  (goby.field) = { description: "Output format to convert file to." }
67  ];
68 
69  optional bool write_hdf5_zero_length_dim = 31 [
70  default = true,
71  (goby.field) = {
72  description: "If false, do not write HDF5 entries with zero-length dimensions (use NULL). This would be set false to workaround older buggy Java implementations of HDF5. Leave default (true) otherwise."
73  cfg { action: DEVELOPER }
74  }
75 
76  ];
77 
78  // if enabled, write a chunked file in pieces, flushing every
79  // hdf5_chunk_length messages to ensure we do not use as much RAM
80  optional int32 hdf5_chunk_length = 32 [(goby.field) = {
81  description: "Set to the HDF chunk length to enable HDF5 chunking (in number of messages per file chunk). This will greatly reduce RAM usage on processing larger .goby files at the expense of somewhat larger .h5 output. The smaller the chunk length the less RAM used by goby_log_tool."
82  cfg { action: ADVANCED }
83  }];
84 
85  optional int32 hdf5_compression_level = 33 [(goby.field) = {
86  description: "Set to a value from 0 (no compression) to 9 (max compression). Requires --hdf5_chunk_length to be set as HDF5 requires chunking for compression."
87  cfg { action: ADVANCED }
88  }];
89 
90  repeated string load_shared_library = 40
91  [(goby.field).description =
92  "Load a shared library (e.g., to load Protobuf files)"];
93 }