Skip to content

Commit

Permalink
minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
ilkilic committed Aug 27, 2024
1 parent c346933 commit 3a92191
Show file tree
Hide file tree
Showing 7 changed files with 312 additions and 517 deletions.
2 changes: 1 addition & 1 deletion examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This directory includes various examples demonstrating how to use BluePyEModel:

- [**L5PC**](./L5PC/README.rst): Provides a guide for setting up and running the E-Model building pipeline locally on a personal computer or on a Slurm cluster. This is an example based on the juvenile (P14) rat somatosensory cortex layer 5 thick-tufted pyramidal cell (L5TPC) e-model optimisation of the [SSCxEModelExamples](https://github.com/BlueBrain/SSCxEModelExamples/tree/main/optimization) repository.

- [**simplecell**](./simplecell/simplecell.ipynb): Demonstrates creating a single-compartment neuron model with two parameters using non-threshold optimization.
- [**simplecell**](./simplecell/simplecell.ipynb): Demonstrates creating a single-compartment neuron model with two parameters using rheobase independent optimisation.

- [**nexus**](./nexus/README.md): Demonstrates the use of BluePyEModel through the Nexus access point.

Expand Down
1 change: 0 additions & 1 deletion examples/simplecell/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,4 @@ recordings/
__pycache__/
ephys_data/
myvenv/
final.json
final_tmp.json
33 changes: 33 additions & 0 deletions examples/simplecell/config/extract_config/simplecell_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,39 @@
"strict_stiminterval": true
}
},
{
"efeature": "Spikecount",
"protocol": "IDrest",
"amplitude": 0.4,
"tolerance": 0.1,
"efeature_name": null,
"weight": 1.0,
"efel_settings": {
"strict_stiminterval": true
}
},
{
"efeature": "mean_frequency",
"protocol": "IDrest",
"amplitude": 0.4,
"tolerance": 0.1,
"efeature_name": null,
"weight": 1.0,
"efel_settings": {
"strict_stiminterval": true
}
},
{
"efeature": "voltage_base",
"protocol": "IDrest",
"amplitude": 0.4,
"tolerance": 0.1,
"efeature_name": null,
"weight": 1.0,
"efel_settings": {
"strict_stiminterval": true
}
},
{
"efeature": "voltage_base",
"protocol": "IV",
Expand Down
105 changes: 90 additions & 15 deletions examples/simplecell/config/features/simplecell.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,84 +5,135 @@
"protocol_name": "IDrest_0.256",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.01,
"default_std_value": 0.001,
"mean": 6.6,
"original_std": 4.5431266766402185,
"sample_size": 5,
"efeature_name": "Spikecount",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -20.0,
"interp_step": 0.025
"Threshold": -50.11250305175781
}
},
{
"efel_feature_name": "mean_frequency",
"protocol_name": "IDrest_0.256",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.01,
"default_std_value": 0.001,
"mean": 4.6549665308108965,
"original_std": 1.7066939148229534,
"sample_size": 4,
"efeature_name": "mean_frequency",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -20.0,
"interp_step": 0.025
"Threshold": -50.11250305175781
}
},
{
"efel_feature_name": "voltage_base",
"protocol_name": "IDrest_0.256",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.01,
"default_std_value": 0.001,
"mean": -84.9396882128033,
"original_std": 0.3331013733422112,
"sample_size": 5,
"efeature_name": "voltage_base",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -20.0,
"interp_step": 0.025
"Threshold": -50.11250305175781
}
},
{
"efel_feature_name": "Spikecount",
"protocol_name": "IDrest_0.4",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.001,
"mean": 13.0,
"original_std": 0.001,
"sample_size": 1,
"efeature_name": "Spikecount",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -50.11250305175781
}
},
{
"efel_feature_name": "mean_frequency",
"protocol_name": "IDrest_0.4",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.001,
"mean": 6.888329580058474,
"original_std": 0.001,
"sample_size": 1,
"efeature_name": "mean_frequency",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -50.11250305175781
}
},
{
"efel_feature_name": "voltage_base",
"protocol_name": "IDrest_0.4",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.001,
"mean": -85.36351310593709,
"original_std": 0.001,
"sample_size": 1,
"efeature_name": "voltage_base",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -50.11250305175781
}
},
{
"efel_feature_name": "voltage_base",
"protocol_name": "IV_-0.147",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.01,
"default_std_value": 0.001,
"mean": -84.5937809414334,
"original_std": 0.25958992541480197,
"sample_size": 5,
"efeature_name": "voltage_base",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -20.0,
"interp_step": 0.025
"Threshold": -64.5374984741211
}
},
{
"efel_feature_name": "ohmic_input_resistance_vb_ssse",
"protocol_name": "IV_-0.147",
"recording_name": "soma.v",
"threshold_efeature_std": null,
"default_std_value": 0.01,
"default_std_value": 0.001,
"mean": 47.95114886552402,
"original_std": 1.5928203273461563,
"sample_size": 5,
"efeature_name": "ohmic_input_resistance_vb_ssse",
"weight": 1.0,
"efel_settings": {
"interp_step": 0.025,
"strict_stiminterval": true,
"Threshold": -20.0,
"interp_step": 0.025
"Threshold": -64.5374984741211
}
}
],
Expand Down Expand Up @@ -111,6 +162,30 @@
"protocol_type": "Protocol",
"stochasticity": false
},
{
"name": "IDrest_0.4",
"stimuli": [
{
"delay": 700.0000000000001,
"amp": 0.3318749852478504,
"thresh_perc": null,
"duration": 2000.0,
"totduration": 3000.0,
"holding_current": -0.02656250074505806
}
],
"recordings_from_config": [
{
"type": "CompRecording",
"name": "IDrest_0.4.soma.v",
"location": "soma",
"variable": "v"
}
],
"validation": true,
"protocol_type": "Protocol",
"stochasticity": false
},
{
"name": "IV_-0.147",
"stimuli": [
Expand Down
15 changes: 1 addition & 14 deletions examples/simplecell/config/recipes.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,26 +11,13 @@
"features": "config/features/simplecell.json",
"pipeline_settings": {
"path_extract_config": "config/extract_config/simplecell_config.json",
"plot_extraction": true,
"default_std_value": 0.01,
"extract_absolute_amplitudes": true,
"efel_settings":{
"strict_stiminterval": true,
"Threshold": -20.0,
"interp_step": 0.025
},
"optimisation_timeout": 300,
"optimiser": "SO-CMA",
"max_ngen": 5,
"optimisation_params": {
"offspring_size": 20
},
"validation_threshold": 100,
"plot_currentscape": true,
"currentscape_config": {
"title": "simplecell"
},
"validation_protocols": [],
"validation_protocols": ["IDrest_0.4"],
"morph_modifiers": []
}
}
Expand Down
42 changes: 42 additions & 0 deletions examples/simplecell/final.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"simplecell__1": {
"emodel": "simplecell",
"etype": "cADpyr",
"ttype": null,
"mtype": null,
"species": "rat",
"brain_region": "SSCX",
"iteration": null,
"synapse_class": null,
"allen_notation": null,
"score": 1257.8671455915864,
"parameters": {
"gnabar_hh.somatic": 0.10623315844384061,
"gkbar_hh.somatic": 0.026127548830000066
},
"fitness": {
"IDrest_0.256.soma.v.Spikecount": 0.1320676359488435,
"IDrest_0.256.soma.v.mean_frequency": 250.0,
"IDrest_0.256.soma.v.voltage_base": 6.755673681284991,
"IV_-0.147.soma.v.voltage_base": 0.979404274352486,
"IV_-0.147.soma.v.ohmic_input_resistance_vb_ssse": 250.0,
"IDrest_0.4.soma.v.Spikecount": 250.0,
"IDrest_0.4.soma.v.mean_frequency": 250.0,
"IDrest_0.4.soma.v.voltage_base": 250.0
},
"features": {
"IDrest_0.256.soma.v.Spikecount": 6.0,
"IDrest_0.256.soma.v.mean_frequency": 1105.990783485126,
"IDrest_0.256.soma.v.voltage_base": -82.68936403171544,
"IDrest_0.4.soma.v.Spikecount": 4.0,
"IDrest_0.4.soma.v.mean_frequency": 1333.3333334958297,
"IDrest_0.4.soma.v.voltage_base": -82.5609583626679,
"IV_-0.147.soma.v.voltage_base": -84.8480244239635,
"IV_-0.147.soma.v.ohmic_input_resistance_vb_ssse": 1060.9623644880035
},
"validation_fitness": {},
"validated": false,
"seed": 1,
"pdfs": []
}
}
Loading

0 comments on commit 3a92191

Please sign in to comment.