Index: applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/core/TrainWorker.java
===================================================================
--- applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/core/TrainWorker.java	(revision 31554)
+++ applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/core/TrainWorker.java	(revision 31564)
@@ -105,6 +105,10 @@
         this.frequency = frequency;
         this.topKIsSelected = topKIsSelected;
-        
-        inputFileName = inputFilePath.substring(inputFilePath.lastIndexOf("/"));
+        if(System.getProperty("os.name").contains("ux")){
+            inputFileName = inputFilePath.substring(inputFilePath.lastIndexOf("/"));
+        }
+        else{
+            inputFileName = inputFilePath.substring(inputFilePath.lastIndexOf("\\"));
+        }
         System.out.println("find parent directory, create osmrec dir for models: " + new File(inputFilePath).getParentFile());
         modelDirectoryPath = new File(inputFilePath).getParentFile() + "/OSMRec_models";
Index: applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/OSMRecPluginHelper.java
===================================================================
--- applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/OSMRecPluginHelper.java	(revision 31554)
+++ applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/OSMRecPluginHelper.java	(revision 31564)
@@ -1495,9 +1495,19 @@
                     String svmModelPath = fileChooser.getSelectedFile().getAbsolutePath();
                     String svmModelText;
-                    if(svmModelPath.contains("/")){
-                        svmModelText = svmModelPath.substring(svmModelPath.lastIndexOf("/"));
+                    if(System.getProperty("os.name").contains("ux")){
+                        if(svmModelPath.contains("/")){
+                            svmModelText = svmModelPath.substring(svmModelPath.lastIndexOf("/"));
+                        }
+                        else{
+                            svmModelText = svmModelPath;
+                        }
                     }
                     else{
-                        svmModelText = svmModelPath;
+                         if(svmModelPath.contains("\\")){
+                            svmModelText = svmModelPath.substring(svmModelPath.lastIndexOf("/"));
+                        }
+                        else{
+                            svmModelText = svmModelPath;
+                        }                       
                     }
                     combinationDefaultListModel.addElement(svmModelText);
Index: applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/personalization/TrainByUser.java
===================================================================
--- applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/personalization/TrainByUser.java	(revision 31554)
+++ applications/editors/josm/plugins/OSMRecPlugin/src/org/openstreetmap/josm/plugins/osmrec/personalization/TrainByUser.java	(revision 31564)
@@ -100,5 +100,11 @@
         System.out.println("find parent directory, create osmrec dir for models: " + new File(inputFilePath).getParentFile());
         
-        inputFileName = inputFilePath.substring(inputFilePath.lastIndexOf("/"));
+        if(System.getProperty("os.name").contains("ux")){
+            inputFileName = inputFilePath.substring(inputFilePath.lastIndexOf("/"));
+        }
+        else{
+            inputFileName = inputFilePath.substring(inputFilePath.lastIndexOf("\\"));
+        }
+        
         modelDirectoryPath = new File(inputFilePath).getParentFile() + "/OSMRec_models";
         //textualDirectoryPath = new File(inputFilePath).getParentFile() + "/OSMRec_models/textualList.txt";
