Skip to content

Commit

Permalink
Merge pull request #345 from deeptools/release2.2.1
Browse files Browse the repository at this point in the history
Release 2.2.1
  • Loading branch information
joachimwolff committed Feb 8, 2019
2 parents 6186d9a + 732e813 commit 018edba
Show file tree
Hide file tree
Showing 8 changed files with 51 additions and 20 deletions.
11 changes: 10 additions & 1 deletion docs/content/News.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,18 @@
News and Developments
=====================


Release 2.2.1
-------------
**7 February 2019**

- Muting log output of matplotlib and cooler
- Set version number of hicmatrix to 5, reason is version 5 depends on cooler version 0.7.11 and hicmatrix version 6 on 0.8.2. This cooler version has a significant performance drop for writing matrices.
- Optional parameter for hicInfo to write the result to a file instead to the bash

Release 2.2
-----------
**10 December 2018**
**18 January 2019**

This release contains:

Expand Down
5 changes: 3 additions & 2 deletions docs/content/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,15 @@ Requirements
* pytables >= 3.4
* pyBigWig >= 0.3
* future >= 0.17
* cooler >= 0.7.11
* six >= 1.11
* jinja2 >= 2.10
* pandas >= 0.23
* unidecode >= 1.0
* hicmatrix >= 5
* hicmatrix = 5
* pygenometracks >= 2.1
* psutil >= 5.4.8
* hic2cool >= 0.4


Command line installation using ``conda``
-----------------------------------------
Expand Down
3 changes: 3 additions & 0 deletions hicexplorer/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('matplotlib').setLevel(logging.WARNING)
logging.getLogger('cooler').setLevel(logging.WARNING)

import warnings
import sys

Expand Down
2 changes: 1 addition & 1 deletion hicexplorer/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# This file is originally generated from Git information by running 'setup.py
# version'. Distribution tarballs contain a pre-generated copy of this file.

__version__ = '2.2'
__version__ = '2.2.1'
41 changes: 29 additions & 12 deletions hicexplorer/hicInfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ def parse_arguments(args=None):
required=True)

parserOpt = parser.add_argument_group('Optional arguments')

parserOpt.add_argument('--outFileName', '-o',
help='File name to save information of the matrix instead of writing it to the bash.'
)
parserOpt.add_argument('--help', '-h', action='help', help='show this help message and exit')

parserOpt.add_argument('--version', action='version',
Expand All @@ -58,14 +60,29 @@ def main():

chromosomes = list(hic_ma.chrBinBoundaries)

print("File:\t{}".format(matrix))
print("Size:\t{:,}".format(size))
print("Sum:\t{:,}".format(sum_elements))
print("Bin_length:\t{}".format(bin_length))
print("Chromosomes:\t{}".format(", ".join(toString(chromosomes))))
print("Non-zero elements:\t{:,}".format(num_non_zero))
print("Minimum (non zero):\t{}".format(min_non_zero))
print("Maximum:\t{}".format(max_non_zero))
print("NaN bins:\t{}".format(num_nan_bins))
if check_cooler(matrix):
hic_ma.getInformationCoolerBinNames()
if args.outFileName:
with open(args.outFileName, 'w') as file:
file.write("# Matrix information file. Created with HiCExplorer's hicInfo version {}\n".format(__version__))
file.write("File:\t{}\n".format(matrix))
file.write("Size:\t{:,}\n".format(size))
file.write("Sum:\t{:,}\n".format(sum_elements))
file.write("Bin_length:\t{}\n".format(bin_length))
file.write("Chromosomes:\t{}\n".format(", ".join(toString(chromosomes))))
file.write("Non-zero elements:\t{:,}\n".format(num_non_zero))
file.write("Minimum (non zero):\t{}\n".format(min_non_zero))
file.write("Maximum:\t{}\n".format(max_non_zero))
file.write("NaN bins:\t{}\n".format(num_nan_bins))
if check_cooler(matrix):
file.write('The following columns are available: {}'.format(hic_ma.getInformationCoolerBinNames()))
else:
print("File:\t{}".format(matrix))
print("Size:\t{:,}".format(size))
print("Sum:\t{:,}".format(sum_elements))
print("Bin_length:\t{}".format(bin_length))
print("Chromosomes:\t{}".format(", ".join(toString(chromosomes))))
print("Non-zero elements:\t{:,}".format(num_non_zero))
print("Minimum (non zero):\t{}".format(min_non_zero))
print("Maximum:\t{}".format(max_non_zero))
print("NaN bins:\t{}".format(num_nan_bins))
if check_cooler(matrix):
print('The following columns are available: {}'.format(hic_ma.getInformationCoolerBinNames()))
2 changes: 1 addition & 1 deletion hicexplorer/utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,6 @@ def remove_non_ascii(pText):


def check_cooler(pFileName):
if pFileName.endswith('.cool') or cooler.io.is_cooler(pFileName) or'.mcool' in pFileName:
if pFileName.endswith('.cool') or cooler.fileops.is_cooler(pFileName) or'.mcool' in pFileName:
return True
return False
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,6 @@ future >= 0.17.*
unidecode >= 1.0.*
hic2cool >= 0.4.*
psutil >= 5.4.8
hicmatrix >= 5
hicmatrix >= 7
cooler >= 0.8.2
pygenometracks >= 2.1
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,10 @@ def checkProgramIsInstalled(self, program, args, where_to_download,
"pyBigWig >= 0.3.*",
"six >= 1.11.*",
"future >= 0.17.*",
"cooler >= 0.7.11*",
"cooler >= 0.8.2*",
"jinja2 >= 2.10.*",
"unidecode >= 1.0.*",
"hicmatrix >= 5",
"hicmatrix >= 7",
"pygenometracks >= 2.1",
"psutil >= 5.4.8",
"hic2cool >= 0.4"
Expand Down

0 comments on commit 018edba

Please sign in to comment.