From c7d236811e9be3f2c317b9d09b8f85a41a8565a8 Mon Sep 17 00:00:00 2001
From: istkabra <kyrill.abrams@stud.h-da.de>
Date: Tue, 2 Jun 2020 16:21:45 +0200
Subject: [PATCH] * Fixed bug when jobName is left empty for timestamp * Each
 job now gets his own image series folder

---
 src/main/java/MainClasses/Config.java | 7 +++----
 src/main/resources/genetic.properties | 2 +-
 2 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/src/main/java/MainClasses/Config.java b/src/main/java/MainClasses/Config.java
index 40ae168..356e1e6 100644
--- a/src/main/java/MainClasses/Config.java
+++ b/src/main/java/MainClasses/Config.java
@@ -150,9 +150,8 @@ public class Config {
         crossoverMultiplier = Double.parseDouble(this.properties.getProperty("crossoverMultiplier"));
 
         // Output settings
-        if(properties.containsKey("jobName")){
-            jobName = this.properties.getProperty("jobName");
-        }else{
+        jobName = this.properties.getProperty("jobName");
+        if(jobName.equals("")) {
             SimpleDateFormat formatter = new SimpleDateFormat("ddMMyyyyHHmmss");
             Date date = new Date();
             jobName = formatter.format(date);
@@ -275,7 +274,7 @@ public class Config {
     }
 
     public String getImageSequenceDirectory() {
-        return imageSequenceDirectory;
+        return imageSequenceDirectory + "/" + jobName;
     }
 
     public String getVideoDirectory() {
diff --git a/src/main/resources/genetic.properties b/src/main/resources/genetic.properties
index 6a23d74..117b374 100644
--- a/src/main/resources/genetic.properties
+++ b/src/main/resources/genetic.properties
@@ -9,7 +9,7 @@
     # Size of the population in one generation
         populationSize = 100
     # Number of generations to run the algorithm for
-        noGenerations = 600
+        noGenerations = 20
     # Type of population initialization [curl | straight | random]
         initializationMethod = random
     # Type of selection that should be used [proportional | tournament | onlybest]
-- 
GitLab