Fixing an issue with the security of the server by replacing all the …#6
Open
marwan-abdellah wants to merge 3 commits intoNeuroBox3D:masterfrom
Open
Fixing an issue with the security of the server by replacing all the …#6marwan-abdellah wants to merge 3 commits intoNeuroBox3D:masterfrom
marwan-abdellah wants to merge 3 commits intoNeuroBox3D:masterfrom
Conversation
…urrlib calls with requests.
Member
|
Thanks for the contribution @marwan-abdellah - I will have a look! |
stephanmg
reviewed
Jul 28, 2023
| """Making use of the REST API (NeuroMorpho.org v7, and updated to v8.5) to query the database.""" | ||
|
|
||
| import re, sys, os, requests | ||
|
|
stephanmg
reviewed
Jul 28, 2023
| """ | ||
|
|
||
| if not os.path.isdir(directory): | ||
| os.mkdir(directory) |
stephanmg
reviewed
Jul 28, 2023
| for neuron in range(0, num_neurons): | ||
| # get each file | ||
| if index == -1: get_swc_by_neuron_name(neurons['_embedded']['neuronResources'][neuron]['neuron_name']) | ||
| if index == -1: |
stephanmg
reviewed
Jul 28, 2023
| @@ -0,0 +1,1008 @@ | |||
| import os | |||
| import joblib | |||
Member
There was a problem hiding this comment.
Unused import, remove please.
stephanmg
reviewed
Jul 28, 2023
| @@ -0,0 +1,1008 @@ | |||
| import os | |||
| import joblib | |||
| import subprocess | |||
stephanmg
reviewed
Jul 28, 2023
| def execute_commands_parallel(shell_commands): | ||
| from joblib import Parallel, delayed | ||
| Parallel(n_jobs=os.cpu_count())(delayed(execute_command)(i) for i in shell_commands) | ||
|
|
stephanmg
requested changes
Jul 28, 2023
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…urrlib calls with requests.