-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix for broken ant file when using no IDE like Netbeans, minor adjust…
…ment for cell type stuff in Backend and some help text for SimpleCLI added.
- Loading branch information
Showing
3 changed files
with
32 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -75,6 +75,7 @@ public static void main(String... args) { | |
/// flags | ||
boolean open_only = false; | ||
boolean force = false; | ||
boolean with_cell_type = false; | ||
if (args.length == 5) { | ||
if ("OPEN".equalsIgnoreCase(args[4])) { open_only = true; } | ||
} | ||
|
@@ -83,6 +84,12 @@ public static void main(String... args) { | |
if ("FORCE".equalsIgnoreCase(args[5]) || ! args[5].isEmpty()) { force = true; } | ||
} | ||
|
||
if (args.length == 7) { | ||
if ("TRUE".equalsIgnoreCase(args[6])) { | ||
with_cell_type = true; | ||
} | ||
} | ||
|
||
try { | ||
final NGBackend backend = new NGBackend(); | ||
backend.create_and_open_project(project_base_dir, NeuGenConstants.NEOCORTEX_PROJECT, force, open_only); | ||
|
@@ -93,7 +100,7 @@ public static void main(String... args) { | |
} | ||
|
||
backend.generate_network(project_type); | ||
backend.export_network(export_format, output_name); | ||
backend.export_network(export_format, output_name, with_cell_type); | ||
} catch (Exception e) { | ||
logger.fatal(e); | ||
e.printStackTrace(); | ||
|
@@ -105,9 +112,15 @@ public static void main(String... args) { | |
* @brief prints usage for the simple CLI | ||
*/ | ||
private static void usage() { | ||
System.out.println("Usage: SimpleCLI PROJECT_BASE_DIR PROJECT_TYPE EXPORT_FORMAT OUTPUT_NAME [OPEN_OR_CREATE] [FORCE]"); | ||
System.out.println("Project type either Neocortex or Hippocampus"); | ||
System.out.println("Export format: TXT, HOC or NGX"); | ||
System.out.println("Note: Only the first four parameters are mandatory."); | ||
System.out.println("Usage: SimpleCLI PROJECT_BASE_DIR PROJECT_TYPE EXPORT_FORMAT OUTPUT_NAME [OPEN_OR_CREATE] [FORCE] [WITH_CELL_TYPE]"); | ||
System.out.println("\tProject base dir on your FS where the project is located"); | ||
System.out.println("\tProject type either Neocortex or Hippocampus"); | ||
System.out.println("\tExport format: TXT, HOC or NGX"); | ||
System.out.println("\tOutput name on your FS for the exported network given your format"); | ||
System.out.println("\tOpen or create: Depending on your choise you can start with a new project or a existing project (specifeid by project base dir). Default OPEN."); | ||
System.out.println("\tForce: If CREATE was chosen previously, specify also FORCE to override if you specify an existing project location. Default. FALSE"); | ||
System.out.println("\tWith cell type: True or False, depending if we want the cell type to be encoded"); | ||
System.out.println("\tNote: Only the first four parameters are mandatory."); | ||
System.out.println("In case of any questions contact: [email protected]"); | ||
} | ||
} |