Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
357 commits
Select commit Hold shift + click to select a range
e085071
{AH} move htslib etc versions to 1.5 on travis
AndreasHeger Jul 3, 2017
9944973
{AH} remove time, needs to be installed
AndreasHeger Jul 3, 2017
3b49b59
{AH] disable vcf test 12
AndreasHeger Jul 4, 2017
d4cd1b8
{AH] cleanup after testing
AndreasHeger Jul 4, 2017
788ade2
{AH} remove superfluous cd
AndreasHeger Jul 5, 2017
cd0bed0
{AH} more cleaning up
AndreasHeger Jul 5, 2017
d0716d0
Merge branch 'master' into pytest-testing
AndreasHeger Jul 6, 2017
af861c2
Merge pull request #498 from pysam-developers/pytest-testing
AndreasHeger Jul 6, 2017
1c28fcb
{AH} add FastxRecord, replaces PersistentFastqProxy
AndreasHeger Jul 10, 2017
cdef6c8
{AH} FastxRecord raises ValueError if no name or sequence
AndreasHeger Jul 10, 2017
19fd140
{AH} FastxRecord raises ValueError if no name or sequence
AndreasHeger Jul 10, 2017
2381a57
{AH} add rpath linking test
AndreasHeger Jul 10, 2017
200bf2c
{AH} fix BAM_DATADIR
AndreasHeger Jul 10, 2017
f617dc8
{AH} add without rpath tests
AndreasHeger Jul 10, 2017
fdd852f
Merge branch 'master' into AH-faidx-instantiate-records
AndreasHeger Jul 10, 2017
1c766c0
{AH} update docs of infer_query_length, see #494
AndreasHeger Jul 10, 2017
3269beb
{AH} fix return code if read_name is identical, issue with memory fau…
AndreasHeger Jul 10, 2017
368dd1b
Merge pull request #502 from pysam-developers/AH-faidx-instantiate-re…
AndreasHeger Jul 21, 2017
7b1cc91
{AH} fix Memory error detection
AndreasHeger Jul 21, 2017
c892ae9
Merge pull request #510 from pysam-developers/AH-add-linking-tests
AndreasHeger Jul 21, 2017
f5da479
Merge branch 'master' into {AH}-tabix_add_line_skip
AndreasHeger Jul 21, 2017
649194d
Merge pull request #511 from pysam-developers/{AH}-tabix_add_line_skip
AndreasHeger Jul 21, 2017
3b98db3
Fix bcf_translate to skip deleted INFO fields to avoid segfaults (#513)
bioinformed Jul 22, 2017
1e50107
Fix temp file paths used in tests (#514)
bioinformed Jul 22, 2017
09af3e8
Update glossary entry for CIGAR
Jul 22, 2017
be1d943
Correct error return in pysam_bam_update
Jul 22, 2017
261da66
Remove incorrect use of inline declarations in external Cython defini…
Jul 22, 2017
055de7f
Refactor region_parsing and related code to HTSFile base class.
Jul 22, 2017
30ff0c8
Merge pull request #515 from pysam-developers/refactor-parse-region
bioinformed Jul 22, 2017
70ea6a8
Use htslib and utils functions to ensure linking is working
Jul 23, 2017
78e95ef
Expose IO errors via IOError exceptions (#516)
bioinformed Jul 24, 2017
79a6494
{AH} separate header into AlignmentHeader from AlignmentFile, closes …
AndreasHeger Jul 24, 2017
28c6388
{AH} add get_index_statistics method, closes #512
AndreasHeger Jul 24, 2017
cb799af
Fix bcf_translate to skip deleted FORMAT fields to avoid segfaults (#…
Jul 26, 2017
41bbc42
Add linking method used prior to PR #489
Jul 26, 2017
6da12b1
skip usage() tests on autobuilders
vorlonofportland Jul 28, 2017
8237510
{AH} tighten code with Kevin's comments
AndreasHeger Jul 31, 2017
96a4c2d
{AH} fix test file path
AndreasHeger Jul 31, 2017
31eecdc
{AH} add test - writing to missing path
AndreasHeger Jul 31, 2017
7796cdc
{AH} remove dependency on WORKDIR in tests. Writting to missing Align…
AndreasHeger Jul 31, 2017
0d57a2c
{AH} refactor AlignmentHeader to be constructed de-novo
AndreasHeger Jul 31, 2017
233386e
Merge pull request #520 from vorlonofportland/no-usage-test-without-tty
AndreasHeger Jul 31, 2017
4721463
{AH} ensure that template/header/reference_names are defined when wri…
AndreasHeger Jul 31, 2017
68fc5df
Fix link to tabix (#522)
nh13 Aug 1, 2017
27d8452
Simplify file detection logic and allow remote index files (#521)
bioinformed Aug 1, 2017
fce8bf1
Handle unset ref when creating new records
Aug 8, 2017
da3e8b4
Merge pull request #526 from msto/MS_new_record_bugfix
bioinformed Aug 8, 2017
b16167d
{AH} update 0.12.0 release notes
AndreasHeger Aug 21, 2017
bcd812e
{AH} make conda the recommended installation method
AndreasHeger Aug 21, 2017
7eef15c
{AH} add total field
AndreasHeger Aug 21, 2017
bd4d8f9
Merge pull request #530 from pysam-developers/AH-addGetIndexStatistics
AndreasHeger Aug 21, 2017
656f299
Fix bcf_translate to operate on INFO and FORMAT values that must be f…
Aug 24, 2017
db17553
Allow for building out of tree
SoapGentoo Sep 3, 2017
a67b90f
{AH} auto-generate bcftools/config.h (and add to repo for good measur…
AndreasHeger Sep 6, 2017
13fca0d
{AH} remove config.h from tar-ball
AndreasHeger Sep 6, 2017
ff49b8a
Merge pull request #532 from SoapGentoo/fix-out-of-source-building
AndreasHeger Sep 7, 2017
8728620
Add test for indexing tabix file to custom location
mvdbeek Sep 12, 2017
16a5e73
Allow indexing file to be created in custom location
mvdbeek Sep 12, 2017
36ffac7
Move `index` to last argument and document it in docstring
mvdbeek Sep 12, 2017
43e02a8
Add tabix gzip detection instead of assuming based on filename. Also…
dannon Sep 12, 2017
51d7e55
Add line skip back, dropped in rebase/shuffle.
dannon Sep 12, 2017
f07d90f
Merge pull request #537 from mvdbeek/specify_index_filename_tabix_index
AndreasHeger Sep 18, 2017
ec7a619
{AH} execute linking tests only when explicitely requested via PYSAM_…
AndreasHeger Sep 18, 2017
4c11a56
Merge pull request #540 from pysam-developers/AH-MakeLinkingTestsOpti…
AndreasHeger Sep 18, 2017
ae1e884
{AH} rename helper function to prevent it from being picked up by nos…
AndreasHeger Sep 18, 2017
3f33919
{AH} set is_modified flag in setAttribute, fixes #546
AndreasHeger Oct 2, 2017
7936499
{AH} use FastaFile instead of Fastafile in pileup(), fixes #543
AndreasHeger Oct 2, 2017
3b037c1
{AH} change conda channel order to solve liblzma issue(?) on osx py27
AndreasHeger Oct 9, 2017
7ecee48
{AH} add missing tags, fixes #531
AndreasHeger Oct 9, 2017
86d30ba
{AH} add htslib conda dependencies explicitely.
AndreasHeger Oct 9, 2017
2fd70d9
{AH} add htslib conda dependencies explicitely to install section
AndreasHeger Oct 9, 2017
70b4aa7
{AH} disable lzma in travis tests
AndreasHeger Oct 9, 2017
2bff3ea
{AH} add report header reading, fixes #544
AndreasHeger Oct 9, 2017
a8de406
{AH} use uint8_t typecodes throughout
AndreasHeger Oct 20, 2017
21d86b9
{AH} disable remote tabix test without libcurl
AndreasHeger Oct 20, 2017
2e58d0a
Merge pull request #551 from pysam-developers/AH-add-missing-BAM-tag-…
AndreasHeger Oct 20, 2017
caba830
{AH} use encoding for header parsing
AndreasHeger Oct 20, 2017
ca4bc1a
Merge pull request #550 from pysam-developers/AH-get_tabix_header_for…
AndreasHeger Oct 20, 2017
4c5f606
{AH} force ord for py2
AndreasHeger Oct 22, 2017
75e6dd5
{AH} force ord for py2, but not ord for py3
AndreasHeger Oct 22, 2017
83ac50b
{AH} force ord for py2, but not ord for py3
AndreasHeger Oct 22, 2017
fe6cbfa
{AH} upgrade to htslib/etc 1.6
AndreasHeger Oct 23, 2017
d326e71
{AH} disable bam2fq test until samtools 1.6 available
AndreasHeger Oct 24, 2017
b087749
{AH} add win dir
AndreasHeger Oct 24, 2017
782adbe
{AH} fix test cases
AndreasHeger Oct 27, 2017
f065647
{AH} update INSTALL and add NEWS, closes #545
AndreasHeger Oct 27, 2017
413d396
{AH} add htslib/win to MANIFEST
AndreasHeger Oct 27, 2017
5603783
Merge branch 'master' into AH-htslib1.6
AndreasHeger Oct 27, 2017
16b5ed7
Merge pull request #558 from pysam-developers/AH-htslib1.6
AndreasHeger Oct 27, 2017
ff40f1b
Assert on reads with invalid MD tags
ramyala Oct 30, 2017
d0cfa72
Account for insertion length in max MD ref calculation
ramyala Oct 31, 2017
0e08158
Merge pull request #561 from lexentbio/assert_on_invalid_md_tags
AndreasHeger Nov 3, 2017
c58ad7d
{AH} upgrade travis to htslib 1.6
AndreasHeger Nov 3, 2017
9af7cee
{AH} update release notes
AndreasHeger Nov 4, 2017
1a9ce7b
Improve assert log for mismatched MD tag reads
ramyala Nov 7, 2017
aa63578
Merge pull request #565 from lexentbio/include_insertion_details_in_m…
AndreasHeger Nov 10, 2017
7338256
{AH} add test for assertion of malformed MD tag, closes #560
AndreasHeger Nov 10, 2017
47368f0
{AH} add faidx_bench script
AndreasHeger Nov 10, 2017
79cbc43
{AH} update all benchmarking scripts for pytest
AndreasHeger Nov 10, 2017
a7a0d89
{AH} update gitignore
AndreasHeger Nov 10, 2017
dd8fcb6
Provide default alleles when constructing a new VariantRecord
Nov 16, 2017
a5af488
{AH} add AlignmentFilePileup_bench
AndreasHeger Nov 17, 2017
3561eda
{AH} permit * and . in region strings, fixes #399
AndreasHeger Nov 17, 2017
241e1f4
Merge pull request #572 from pysam-developers/AH-AllowUseOfAsteriskIn…
AndreasHeger Nov 17, 2017
8eb48ca
Keep END for symbolic alleles
Nov 17, 2017
8ac4098
Move symbolic allele check to inline function
Nov 17, 2017
9b1a87e
Cache rlen for symbolic alleles
Nov 17, 2017
053ebf9
{AH} reactivate filepath_index, fixes #443
AndreasHeger Nov 17, 2017
fac0aa4
{AH} solve issue with compressed .fa files.
AndreasHeger Nov 17, 2017
2c997ec
Merge pull request #576 from pysam-developers/AH-reimplement-FastaFil…
AndreasHeger Nov 18, 2017
0dbee77
{AH} first implementation of pileups
AndreasHeger Nov 20, 2017
babd9c1
{AH} faster access to pileup data
AndreasHeger Nov 21, 2017
2a7b984
{AH} updates to benchmarks
AndreasHeger Nov 22, 2017
83c23ff
{AH} updated test utils - merged with benchmarks
AndreasHeger Nov 22, 2017
4b87d06
{AH} update tests
AndreasHeger Nov 22, 2017
eb51ad3
{AH} add min_base_quality option
AndreasHeger Nov 22, 2017
cecff8d
{AH} pep8
AndreasHeger Nov 23, 2017
37c4d10
{AH} parameterize count_coverage tests with new pileup API
AndreasHeger Nov 23, 2017
67b7c8c
{AH} add add_marker and add_indel options to PileupColumn.query_seque…
AndreasHeger Nov 23, 2017
d65e648
{AH} more docs
AndreasHeger Nov 24, 2017
69ca863
{AH} use mplp API instead plp API
AndreasHeger Nov 24, 2017
413d692
{AH} use mplp API instead plp API
AndreasHeger Nov 24, 2017
ff0f6fa
{AH} update tests
AndreasHeger Nov 24, 2017
6d14bcd
{AH} add full parameterization for read filtering
AndreasHeger Nov 24, 2017
13e4372
{AH} add match/mismatch marking
AndreasHeger Nov 24, 2017
cca5735
Check all alternate alleles for symbolic and report idx
Nov 27, 2017
27d1036
Merge pull request #581 from pysam-developers/AH-PileupEngineUpdates
AndreasHeger Nov 28, 2017
bdf7be4
{AH} refactor setup.py, reduce duplications in libraries
AndreasHeger Nov 17, 2017
2da562e
{AH} refactor setup.py, reduce duplications in libraries
AndreasHeger Nov 17, 2017
6175147
{AH} cherry-pick SetupPy refactor commits
AndreasHeger Dec 1, 2017
0408234
{AH} add missing bcftools files
AndreasHeger Dec 1, 2017
e9d330b
{AH} complete module layout refactoring, fixes #443 and #519
AndreasHeger Dec 1, 2017
5900e8e
{AH} add missing benchmark files
AndreasHeger Dec 1, 2017
3ea6e3a
{AH} reads can be built without header
AndreasHeger Dec 1, 2017
77cbeac
{AH} merge with master
AndreasHeger Dec 1, 2017
dd1518c
Merge branch 'AH-AddAlignmentHeader'
AndreasHeger Dec 1, 2017
2f19050
{AH} fix py2 issue: IOError instead of OSError
AndreasHeger Dec 2, 2017
e45a118
Fix loading index without tbi extension
mvdbeek Dec 6, 2017
e07181f
Add regression test for loading index without extension
mvdbeek Dec 6, 2017
8eed3d4
Need to actually use tbx_index_load2
mvdbeek Dec 6, 2017
9e40237
Merge pull request #586 from mvdbeek/load_index_without_tbi_extension
AndreasHeger Dec 8, 2017
a954187
Merge pull request #570 from msto/MS_new_record_alleles
bioinformed Dec 8, 2017
967f399
{AH} fetch benchmarks
AndreasHeger Dec 6, 2017
839d7cc
{AH} add build_reference_sequence function
AndreasHeger Dec 6, 2017
31710cb
{AH} minor cleanup of unused variables and missing types
AndreasHeger Dec 8, 2017
41a7197
{AH} tid can be set to -1 without header and reference_name can be se…
AndreasHeger Dec 8, 2017
47c96e8
{AH} tighten coordinate arguments for count_coverage, fixes #302
AndreasHeger Dec 8, 2017
b43fb6c
{AH} add SQ fields to header if absent, fixes #325
AndreasHeger Dec 8, 2017
4fc6acd
{AH} add get_forward_sequence() and get_forward_qualities() methods, …
AndreasHeger Dec 8, 2017
100b63c
{AH} update ranges in count_coverage tests
AndreasHeger Dec 8, 2017
db5704f
{AH} better return code checking of hts_itr_next, fixes #583
AndreasHeger Dec 8, 2017
a0e18ad
{AH} force_str for py2 compatibility
AndreasHeger Dec 8, 2017
1ff9e9a
{AH} py2 compatibility for maketrans function
AndreasHeger Dec 8, 2017
423d817
{AH} ignore header test in CRAM2CRAM, see #542
AndreasHeger Dec 8, 2017
559556b
Return None from build_alignment_sequence if no MD tag
Dec 13, 2017
e6b79b5
{AH} use alignment length of 1 for unmapped reads, fixes #590
AndreasHeger Dec 15, 2017
d6e5c91
{AH} add benchmarking.rst to docs
AndreasHeger Dec 15, 2017
6214728
Merge pull request #589 from j3harvey/get_reference_no_md
AndreasHeger Dec 15, 2017
0e5cb84
{AH} add PileupColumn.__len__ method, closes #528
AndreasHeger Dec 15, 2017
fabf33f
{AH} add fromstring method, see #577
AndreasHeger Dec 15, 2017
592d282
{AH} add todict/fromdict methods, closes #577
AndreasHeger Dec 15, 2017
3defba9
{AH} rename tostring to to_string throughout
AndreasHeger Dec 15, 2017
be4528c
{AH} permit Number=G in FORMAT records
AndreasHeger Dec 22, 2017
0af73ce
{AH} permit Number=G in FORMAT records
AndreasHeger Dec 22, 2017
a830436
{AH} add ability to create csi indices with tabix_index, closes #591
AndreasHeger Dec 22, 2017
67b5fe6
{AH} add one more csi/bcf test
AndreasHeger Dec 22, 2017
c1ac1cc
Add a format_options keyword to AlignmentFile to allow things like 'r…
dpryan79 Jan 4, 2018
d784900
Free memory on error
dpryan79 Jan 4, 2018
b6b7766
Set default format_options=[] and fix a typo in the last commit
dpryan79 Jan 4, 2018
71ac18f
Set the default format_options to None
dpryan79 Jan 4, 2018
91a94e8
oops, missed one
dpryan79 Jan 4, 2018
1fdbf9d
Make the default None everywhere
dpryan79 Jan 4, 2018
e98512b
Merge pull request #599 from dpryan79/AlignmentFileFormatOptions
AndreasHeger Jan 5, 2018
3bd153e
{AH} add version.h for htslib
AndreasHeger Jan 5, 2018
44ebba4
{AH} add libctabixproxies to __all__, see #443
AndreasHeger Jan 5, 2018
38f6446
{AH} add bcftools reheader to package see #443
AndreasHeger Jan 5, 2018
128ebef
{AH} remove plugins dir from bcftools
AndreasHeger Jan 5, 2018
82158e6
{AH} update test data URLs
AndreasHeger Jan 5, 2018
6adb0cd
{AH} disable libtabproxies import
AndreasHeger Jan 5, 2018
559bbed
{AH} rename main_reheader to main_bcftools_reheader
AndreasHeger Jan 5, 2018
8fba797
{AH} fix import
AndreasHeger Jan 6, 2018
ba80ddd
{AH} add __all__ statement
AndreasHeger Jan 6, 2018
23ad2a4
{AH} fix a \0 issue in header, refactor AlignmentHeader to use classm…
AndreasHeger Jan 12, 2018
9e4f4a0
{AH} add benchmarking scripts for VariantFile
AndreasHeger Jan 12, 2018
239103a
{AH} import of htslib 1.7 and samtools 1.7
AndreasHeger Jan 29, 2018
49c9670
{AH} update htslib/samtools conda deps
AndreasHeger Jan 30, 2018
c28e63c
{AH} updated release notes, closes #608
AndreasHeger Jan 30, 2018
39a3877
Merge pull request #602 from pysam-developers/AH-ClassMethodsforAlign…
AndreasHeger Jan 30, 2018
914977a
{AH} revert change and add test for workaround
AndreasHeger Jan 30, 2018
faf9569
{AH} add test data
AndreasHeger Jan 30, 2018
16ecfee
Merge pull request #594 from pysam-developers/AH-GT-parsing-in-FORMAT…
AndreasHeger Jan 31, 2018
56ee98d
Merge pull request #609 from pysam-developers/htslib-1.7
AndreasHeger Jan 31, 2018
e92f5cd
{AH} fix long cigar parsing in SAM/BAM/CRAM, fixes #613
AndreasHeger Feb 2, 2018
90d3263
{AH} add test for count_coverage() with missing contig, see #610
AndreasHeger Feb 2, 2018
d3c9b79
{AH} update additional type mismatches and fix test
AndreasHeger Feb 5, 2018
eba0deb
{AH} inrcrease test alignment length
AndreasHeger Feb 5, 2018
7ebad1f
Merge pull request #615 from pysam-developers/AH-LongCigars
AndreasHeger Feb 6, 2018
ff0df38
{AH} each iterator now loads own copy of index, fixes #611 and fixes …
AndreasHeger Feb 6, 2018
e5892c3
{AH} fix index setting
AndreasHeger Feb 6, 2018
4849c99
Merge pull request #617 from pysam-developers/AH-DoubleFetchIssue
AndreasHeger Feb 7, 2018
8d77162
{AH} exclude tests from pypi tar-ball
AndreasHeger Feb 6, 2018
b6ca2d2
{AH} updated news
AndreasHeger Feb 8, 2018
48b8ea9
{AH} add backwards compatibility functions for AlignmentHeader, fixes…
AndreasHeger Feb 9, 2018
afdb66c
{AH} add AlignmentFile.text back for compatibily
AndreasHeger Feb 9, 2018
f55c453
{AH} update release notes and versions, fixes #619
AndreasHeger Feb 9, 2018
d84ba01
{AH} fix typo
AndreasHeger Feb 9, 2018
b7ce5e6
{AH} sort for py2.7 in header comparison
AndreasHeger Feb 9, 2018
af6ff23
Merge pull request #620 from pysam-developers/AH-add_alignmentfilehea…
AndreasHeger Feb 9, 2018
c8878a8
modified
wckdouglas Feb 12, 2018
57b72b1
added warning to NULL quality alignments in count_coverage
wckdouglas Feb 12, 2018
505f627
reset setup.py
wckdouglas Feb 12, 2018
6fcee40
reset quality thershold flag
wckdouglas Feb 12, 2018
94924f7
fixed warning
wckdouglas Feb 12, 2018
ac02694
fixed empty QUAL, removed warning and used quality threshold to contr…
wckdouglas Feb 12, 2018
ce895a1
fixed empty QUAL, removed warning and used quality threshold to contr…
wckdouglas Feb 12, 2018
5715b7c
fixed quality check, skip if null quality and quality_threshold == 0 …
wckdouglas Feb 12, 2018
c5d9a13
fixed
wckdouglas Feb 12, 2018
f89911f
fixed if-clause for check base qual
wckdouglas Feb 12, 2018
5d45203
fixed wrong base qual comparison
wckdouglas Feb 12, 2018
6426804
base qual filter using >= to match previous behaviour
wckdouglas Feb 12, 2018
76bec77
{AH} add missing test data, fixes #622
AndreasHeger Feb 12, 2018
e6f18a8
speed up intron
wckdouglas Mar 1, 2018
b7ae8f1
fixed pos bug
wckdouglas Mar 1, 2018
50d6895
added faster function for find_introns
wckdouglas Mar 2, 2018
c56b0d1
uses r.cigartuples for find_introns
wckdouglas Mar 2, 2018
7c605ac
uses added comments for find_introns
wckdouglas Mar 2, 2018
5e46d48
uses cdef types according to get_aligned_pairs for find_introns
wckdouglas Mar 2, 2018
c0fbdeb
removed redundant assignment
wckdouglas Mar 2, 2018
b2d32bc
cythonize alignment
wckdouglas Mar 2, 2018
1a76af1
uses set comparison
wckdouglas Mar 2, 2018
34ba3fc
modified comment
wckdouglas Mar 2, 2018
6b345a3
{AH} fix header access in pileup column
AndreasHeger Mar 16, 2018
12e0701
{AH} treat border case of all bases in pileup column below quality score
AndreasHeger Mar 16, 2018
9b2466b
{AH} remove unsued imports
AndreasHeger Mar 17, 2018
b4adaff
Merge pull request #635 from wckdouglas/speed_up_find_intron
AndreasHeger Mar 17, 2018
ad9c0ab
Merge pull request #621 from wckdouglas/master
AndreasHeger Mar 17, 2018
f164517
{AH} update release notes for v0.14.1
AndreasHeger Mar 20, 2018
96edc75
{AH} double check remote data tests
AndreasHeger Mar 20, 2018
7077972
{AH} add bcftools 1.7
AndreasHeger Mar 20, 2018
09fb70e
{AH} update NEWS
AndreasHeger Mar 20, 2018
aa27e81
Allow setting number of threads for htslib (#638)
mvdbeek May 11, 2018
ca50218
First merge with pysam 0.11.0
Munchic Jun 26, 2018
b750e6d
Regained crypto read functionality
Munchic Jun 26, 2018
085633a
Added libcsamtools.c for CircleCI
Munchic Jun 26, 2018
ca107e9
Added libcbcftools.c for CircleCI
Munchic Jun 26, 2018
b03b570
Merge pull request #5 from Munchic/update/pysam-0.11.0
Munchic Jun 26, 2018
b8ab818
Updated pysam to 0.14.1
Munchic Jun 26, 2018
d0feea9
Uploaded libcbcftools.c for CircleCI
Munchic Jun 26, 2018
0ddfa1c
Merge branch 'crypto' into update/pysam-0.14.1
Munchic Jun 26, 2018
5dfa310
Merged newest block caching implementation
Munchic Jun 30, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Binary file added .DS_Store
Binary file not shown.
18 changes: 5 additions & 13 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ tests/*.sam
tests/*.fai
tests/pysam_data
tests/cbcf_data
tests/tabix_data

samtools/config.h
htslib/config.status
Expand All @@ -26,20 +27,10 @@ htslib/autom4te.cache
htslib/config.cache
htslib/deps.mk

# linking tests
BuildRead.c
# cython files
pysam/TabProxies.c
pysam/csamtools.c
pysam/ctabix.c
pysam/cvcf.c
pysam/chtslib.c
pysam/cutils.c
pysam/calignedsegment.c
pysam/calignmentfile.c
pysam/cbcf.c
pysam/cfaidx.c
pysam/chtslib.c
pysam/csamfile.c
pysam/ctabixproxies.c
pysam/libc*.c

###### Generic python ignores below ######

Expand All @@ -66,6 +57,7 @@ var/
*.egg-info/
.installed.cfg
*.egg
doc/_build

# Installer logs
pip-log.txt
Expand Down
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ env:
- CONDA_PY=3.4
- CONDA_PY=3.5
- CONDA_PY=3.6
global:
- PYSAM_LINKING_TEST=1

addons:
apt:
Expand Down
117 changes: 81 additions & 36 deletions INSTALL
Original file line number Diff line number Diff line change
@@ -1,57 +1,102 @@
System Requirements
===================
An online version of the installation instructions can be found here:
http://pysam.readthedocs.io/en/latest/installation.html

SAMtools depends on the zlib library <http://www.zlib.net>. The latest
version 1.2.3 is preferred and with the latest version you can compile
razip and use it to compress a FASTA file. SAMtools' faidx is able to
index a razip-compressed FASTA file to save diskspace. Older zlib also
works with SAMtools, but razip cannot be compiled.
================
Installing pysam
================

The text-based viewer (tview) requires the GNU ncurses library
<http://www.gnu.org/software/ncurses/>, which comes with Mac OS X and
most of the modern Linux/Unix distributions. If you do not have this
library installed, you can still compile the rest of SAMtools by
manually modifying one line in Makefile.
Pysam can be installed through conda_, pypi_ and from the repository.
The recommended way to install pysam is through conda/bioconda.

curl
Conda installation
==================

Pysam requires Python (2.7 or greater) and Cython (0.22 or greater).
It has not been tested on many other platforms.
To install pysam in your current conda_ environment, type::

Windows support does not work yet.
conda config --add channels r
conda config --add channels bioconda
conda install pysam

Compilation
===========
This will install pysam from the bioconda_ channel and automatically
makes sure that dependencies are installed. Also, compilation flags
will be set automatically, which will potentially save a lot of
trouble on OS X.

Unpack the distribution and enter the pysam directory. Type
Pypi installation
=================

python setup.py build
Pysam provides a python interface to the functionality contained
within the htslib_ C library. There are two ways that these two
can be combined, ``builtin`` and ``external``.

to compile.
Builtin
-------

Installation
============
The typical installation will be through pypi_::

pip install pysam

This will compile the ``builtin`` htslib source code within pysam.

htslib_ can be configured at compilation to turn on additional
features such support using encrypted configurations, enable plugins,
and more. See the htslib_ project for more information on these.

Pysam will attempt to configure htslib_ to turn on some advanced
features. If these fail, for example due to missing library
dependencies (`libcurl`, `libcrypto`), it will fall back to
conservative defaults.

Options can be passed to the configure script explicitely by
setting the environment variable `HTSLIB_CONFIGURE_OPTIONS`.
For example::

Type
export HTSLIB_CONFIGURE_OPTIONS=--enable-plugins
pip install pysam

python setup.py install
External
--------

to install it within the site-packages directory of your python
distribution. Type
pysam can be combined with an externally installed htslib_
library. This is a good way to avoid duplication of libraries. To link
against an externally installed library, set the environment variables
`HTSLIB_LIBRARY_DIR` and `HTSLIB_INCLUDE_DIR` before installing::

python setup.py install --help
export HTSLIB_LIBRARY_DIR=/usr/local/lib
export HTSLIB_INCLUDE_DIR=/usr/local/include
pip install pysam

for more options.
Note that the location of the file :file:`libhts.so` needs to be known
to the linker once you run pysam, for example by setting the
environment-varirable `LD_LIBRARY_PATH`.

Build the documentation
=======================
Note that generally the pysam and htslib version need to be compatible. See
the release notes for more information.

Install a version of Sphinx that matches your Python version (2 or 3) and run
Installation from repository
============================

python setup.py build_sphinx
pysam depends on cython_ to provide the connectivity to the htslib_ C
library. The installation of the source tarball (:file:`.tar.gz`)
contains pre-built C-files and cython needs not be present
during installation. However, when installing from the repository,
cython needs to be installed beforehand.

To install from repository, type::

python setup.py install

For compilation options, see the section on Pypi installation above.

Requirements
============

or
Depending on the installation method, requirements for building pysam differ.

python3 setup.py build_sphinx
When installing through conda_, dependencies will be resolved by the
package manager. The pip_ installation and installation from source
require a C compiler and its standard libraries as well as all
requirements for building htslib. Htslib requirements are listed in
the htslib/INSTALL file.

The documentation will be put into build/sphinx.
Installing from the repository will require cython_ to be installed.
60 changes: 23 additions & 37 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -5,70 +5,56 @@
#
include MANIFEST.in
include COPYING
include NEWS
include INSTALL
include KNOWN_BUGS
include THANKS
include cy_build.py
include requirements.txt
include pysam/c*.pxd
include pysam/c*.pyx
include pysam/c*.c
include pysam/libc*.pxd
include pysam/libc*.pyx
include pysam/libc*.c
include pysam/*.c
include pysam/*.h

# exclude tests from pypi tar-ball - they
# require additional data
prune tests/

# samtools
include samtools/configure
include samtools/config.mk.in
include samtools/config.h.in
include samtools/*.h
include samtools/*.c
exclude samtools/config.h
include samtools/*/*.h

# bcftools
include bcftools/*.h
include bcftools/*.c
exclude bcftools/config.h

# htslib
include htslib/*.c
include htslib/*.h
include htslib/INSTALL
include htslib/NEWS
exclude htslib/config.h
include htslib/Makefile
include htslib/htslib_vars.mk
include htslib/configure
include htslib/config.mk.in
include htslib/config.h.in
include htslib/htslib.pc.in
include htslib/htslib/*.h
include htslib/cram/*.c
include htslib/cram/*.h
include htslib/win/*.c
include htslib/win/*.h
include cy_build.py
include pysam.py
include requirements.txt

# pysam tests
include tests/00README.txt
include tests/pysam_data
include tests/tabix_data
include tests/*.py
#ex1.fa
#include tests/ex1.sam.gz
#include tests/ex3.sam
#include tests/ex4.sam
#include tests/ex5.sam
#include tests/ex6.sam
#include tests/ex7.sam
#include tests/ex8.sam
#include tests/ex9_fail.bam
#include tests/ex9_nofail.bam
#include tests/ex10.sam
#include tests/example.py
#include tests/pysam_test.py
#include tests/segfault_tests.py
#include tests/example_*.sam
#include tests/example_btag.bam
#include tests/tag_bug.bam
#include tests/example.vcf40
#include tests/example_empty_header.bam
#include tests/test_unaligned.bam
#include tests/issue100.bam

# tabix tests
#include tests/example.gtf.gz
#include tests/example.gtf.gz.tbi
#include tests/example.bed.gz
#include tests/example.bed.gz.tbi
#include tests/vcf-examples/*.vcf

# documentation
include doc/*
Loading