Closed aakashsur closed 5 years ago
What version of pysam do you have installed? We are currently using 0.15.3 with this code and it seems to work. header
is the result of calling pysam.AlignmentFile.header
, which is a supported API into the object in the version we are using. We'd prefer to keep using the API if it's compatible with the current version of pysam to avoid interrogating its internal data structures directly.
Looks like that was it, I was in a slurm environment and loading one of the modules switched my python (rude!) which had pysam==0.8.4. Using the latest pysam changes the header format and works as written.
I encountered the following error:
Which traces back to: https://github.com/phasegenomics/hic_qc/blob/1e132fb24fefbe4f27484a4ef35b281b892dcd06/hic_qc.py#L285
Changing line 285 to:
appears to remedy the issue.