Skip to content
This repository was archived by the owner on Feb 26, 2025. It is now read-only.
This repository was archived by the owner on Feb 26, 2025. It is now read-only.

API to close h5 file handler of circuit? #40

@asanin-epfl

Description

@asanin-epfl

I have a situation where I need to edit SONATA circuit nodes and edges. In order to read and edit them I use:

    circuit = Circuit(str(circuit_config_file))
    node = circuit.nodes[node_population_name].get(node_id)
    # adjust node and its edges
    ....
    with h5py.File(nodes_file)

The last line gives me

OSError: Unable to open file (unable to lock file, errno = 35, error message = 'Resource temporarily unavailable')
h5py/h5f.pyx:88: OSError

Can we provide a method to close all h5 files opened by the instance of Circuit?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions