mirror of
https://github.com/azaion/annotations.git
synced 2026-04-22 08:06:31 +00:00
get label files more carefully
put warning min log level put filename to the title
This commit is contained in:
@@ -26,7 +26,7 @@ public partial class App : Application
|
||||
{
|
||||
Log.Logger = new LoggerConfiguration()
|
||||
.Enrich.FromLogContext()
|
||||
.MinimumLevel.Information()
|
||||
.MinimumLevel.Warning()
|
||||
.WriteTo.Console()
|
||||
.WriteTo.File(
|
||||
path: "Logs/log.txt",
|
||||
|
||||
@@ -49,9 +49,6 @@ public class FileConfigRepository(ILogger<FileConfigRepository> logger) : IConfi
|
||||
var exePath = Path.GetDirectoryName(AppDomain.CurrentDomain.BaseDirectory)!;
|
||||
var configFilePath = Path.Combine(exePath, CONFIG_PATH);
|
||||
|
||||
logger.LogInformation($"exePath: {exePath}" );
|
||||
logger.LogInformation($"configFilePath: {configFilePath}");
|
||||
|
||||
if (!File.Exists(configFilePath))
|
||||
{
|
||||
return new Config
|
||||
|
||||
@@ -171,7 +171,7 @@ public partial class MainWindow
|
||||
if (!labelDir.Exists)
|
||||
return;
|
||||
|
||||
var labelFiles = labelDir.GetFiles($"{_formState.VideoName}_*");
|
||||
var labelFiles = labelDir.GetFiles($"{_formState.VideoName}_??????.txt");
|
||||
foreach (var file in labelFiles)
|
||||
{
|
||||
var name = Path.GetFileNameWithoutExtension(file.Name);
|
||||
|
||||
@@ -182,6 +182,7 @@ public class PlayerControlHandler(LibVLC libVLC, MediaPlayer mediaPlayer, MainWi
|
||||
|
||||
mediaPlayer.Stop();
|
||||
mediaPlayer.Play(new Media(libVLC, fileInfo.Path));
|
||||
mainWindow.Title = $"Azaion Annotator - {fileInfo.Name}";
|
||||
mainWindow.BlinkHelp(HelpTexts.HelpTextsDict[HelpTextEnum.PauseForAnnotations]);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"VideosDirectory": "E:\\Azaion3\\VideosDone",
|
||||
"VideosDirectory": "E:\\Azaion3\\Videos",
|
||||
"LabelsDirectory": "E:\\labels",
|
||||
"ImagesDirectory": "E:\\images",
|
||||
"ResultsDirectory": "E:\\results",
|
||||
@@ -54,7 +54,7 @@
|
||||
},
|
||||
{
|
||||
"Id": 8,
|
||||
"Name": "Танк з додатковим захистом",
|
||||
"Name": "Танк з захистом",
|
||||
"Color": "#80008000",
|
||||
"ColorBrush": "#80008000"
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user