Python Code Continues Execution Despite HOC Error
Posted: Tue Apr 02, 2024 5:32 am
I am writing to bring to your attention an issue I encountered while simulating a Purkinje cell using the NEURON simulator with Python code.
Problem Description:
My code is in Python, but some variables and functions of the cell are written in HOC code. While conducting simulations, I observed that if there is an error in the HOC code, the Python code continues to execute without throwing an error. This behaviour can lead to inaccurate results and make debugging more challenging.
Expected Behaviour:
Ideally, when an error occurs in the HOC code during a simulation executed from Python, the execution should halt, and an exception should be raised in the Python environment, allowing the user to identify and address the issue promptly.
Request for Assistance:
I would appreciate any insights or suggestions on how to ensure that errors in the HOC code are properly reported within the Python environment, thereby facilitating debugging and ensuring the accuracy of simulation results.
Thank you in advance for your attention to this matter.
Problem Description:
My code is in Python, but some variables and functions of the cell are written in HOC code. While conducting simulations, I observed that if there is an error in the HOC code, the Python code continues to execute without throwing an error. This behaviour can lead to inaccurate results and make debugging more challenging.
Expected Behaviour:
Ideally, when an error occurs in the HOC code during a simulation executed from Python, the execution should halt, and an exception should be raised in the Python environment, allowing the user to identify and address the issue promptly.
Request for Assistance:
I would appreciate any insights or suggestions on how to ensure that errors in the HOC code are properly reported within the Python environment, thereby facilitating debugging and ensuring the accuracy of simulation results.
Thank you in advance for your attention to this matter.