|
43 | 43 | _has_rest_support = True
|
44 | 44 | except:
|
45 | 45 | _has_rest_support = False
|
| 46 | +try: |
| 47 | + import venv |
| 48 | + _has_venv = True |
| 49 | +except ImportError: |
| 50 | + _has_venv = False |
46 | 51 |
|
47 | 52 | DEFAULT_BLUECONFIG="/nfs4/bbp.epfl.ch/visualization/Circuits/KaustCircuit/BlueConfig"
|
48 | 53 | DEFAULT_APP='circuit_viewer'
|
@@ -446,11 +451,12 @@ def to_bool(x):
|
446 | 451 | # Declares and parses the command line options
|
447 | 452 | def command_line_options(argv):
|
448 | 453 | args_parser = argparse.ArgumentParser(
|
449 |
| - usage="""rtneuron [-h] [-v] [--shell] [--app app_name] |
450 |
| - [-c filename] [--target name [neuron_mode [color]]] |
451 |
| - [-n gid [neuron_mode [color]]] |
452 |
| - [--neurons start_gid end_gid [neuron_mode [color]]] |
453 |
| - [options...]""", |
| 454 | + usage=("rtneuron [-h] [-v] [--shell] " + ( |
| 455 | + "[--venv end_dir] " if _has_venv else "") + """[--app app_name] |
| 456 | + [-c filename] [--target name [neuron_mode [color]]] |
| 457 | + [-n gid [neuron_mode [color]]] |
| 458 | + [--neurons start_gid end_gid [neuron_mode [color]]] |
| 459 | + [options...]"""), |
454 | 460 | description="RTNeuron command line application",
|
455 | 461 | epilog="For further help please check the user guide available at: https://bbp.epfl.ch/documentation/code/RTNeuron-${VERSION_MAJOR}.${VERSION_MINOR}/index.html",
|
456 | 462 | formatter_class=HelpFormatter)
|
@@ -488,6 +494,11 @@ def command_line_options(argv):
|
488 | 494 | help="Start an interactive IPython shell after initialization (or" \
|
489 | 495 | " a regular console if IPython is not available).")
|
490 | 496 |
|
| 497 | + if _has_venv: |
| 498 | + args_parser.add_argument( |
| 499 | + "--venv", type=str, metavar="dirname", |
| 500 | + help="Creates a virtual Python environment in a target directory") |
| 501 | + |
491 | 502 | # Data loading options
|
492 | 503 | group = args_parser.add_argument_group("Data loading options")
|
493 | 504 | group.add_argument(
|
@@ -1023,18 +1034,3 @@ def create_rtneuron_engine_attributes(options):
|
1023 | 1034 | attr.profile.enable = True
|
1024 | 1035 |
|
1025 | 1036 | return attr
|
1026 |
| - |
1027 |
| - # Per layer values for interneurons |
1028 |
| - # Layer 1 Layer 2 Layer 3 Layer 4 Layer 5 Layer 6 |
1029 |
| - # NGC 7.15 NGC 7.61 NGC 7.61 NGC 7.61 NGC 7.61 NGC 7.61 |
1030 |
| - # CRC 7.27 |
1031 |
| - # BP 6.47 BP 6.47 BP 7.10 BP 7.10 BP 7.10 |
1032 |
| - # ChC 8.04 ChC 8.01 ChC 7.97 ChC 8.04 ChC 7.98 |
1033 |
| - # LBC 6.62 LBC 8.53 LBC 8.53 LBC 9.75 LBC 10.03 LBC 9.38 |
1034 |
| - # NBC 7.48 NBC 8.75 NBC 8.87 NBC 8.20 NBC 7.80 NBC 8.75 |
1035 |
| - # MC 9.85 MC 9.41 MC 9.32 MC 8.93 MC 9.48 |
1036 |
| - # ADC 7.72 |
1037 |
| - # AHC 7.53 |
1038 |
| - # DBC 6.46 DBC 6.63 DBC 6.52 DBC 6.63 DBC 6.85 |
1039 |
| - # SBC 6.55 SBC 7.02 SBC 7.19 SBC 9.00 SBC 7.76 SBC 7.79 |
1040 |
| - # BTC 9.13 BTC 9.57 BTC 8.35 BTC 9.36 BTC 9.62 |
0 commit comments