Skip to content

Commit

Permalink
Change default compression level of .hic files from 9 to 10
Browse files Browse the repository at this point in the history
  • Loading branch information
robomics committed Jan 25, 2024
1 parent 458f9dd commit 22494b4
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions docs/cli_reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ hictk convert
When converting from hic to cool, only two threads will be used.
-l,--compression-lvl UINT:INT in [1 - 12] [6]
Compression level used to compress interactions.
Defaults to 6 and 9 for .cool and .hic files, respectively.
Defaults to 6 and 10 for .cool and .hic files, respectively.
-f,--force Overwrite existing files (if any).
hictk dump
Expand Down Expand Up @@ -215,7 +215,7 @@ hictk load
Number of pixels to buffer in memory.
-l,--compression-lvl UINT:INT bounded to [1 - 12]
Compression level used to compress interactions.
Defaults to 6 and 9 for .cool and .hic files, respectively.
Defaults to 6 and 10 for .cool and .hic files, respectively.
-t,--threads UINT:UINT in [1 - 16] [1]
Maximum number of parallel threads to spawn.
When loading interactions in a .cool file, only a single thread will be used.
Expand Down Expand Up @@ -244,7 +244,7 @@ hictk merge
Number of pixels to store in memory before writing to disk.
-l,--compression-lvl UINT:INT bounded to [1 - 12]
Compression level used to compress interactions.
Defaults to 6 and 9 for .cool and .hic files, respectively.
Defaults to 6 and 10 for .cool and .hic files, respectively.
-t,--threads UINT:UINT in [1 - 16] [1]
Maximum number of parallel threads to spawn.
When merging interactions in Cooler format, only a single thread will be used.
Expand Down
4 changes: 2 additions & 2 deletions src/hictk/cli/cli_convert.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ void Cli::make_convert_subcommand() {
"-l,--compression-lvl",
c.compression_lvl,
"Compression level used to compress interactions.\n"
"Defaults to 6 and 9 for .cool and .hic files, respectively.")
"Defaults to 6 and 10 for .cool and .hic files, respectively.")
->check(CLI::Range(1, 12))
->capture_default_str();
sc.add_flag(
Expand Down Expand Up @@ -243,7 +243,7 @@ void Cli::transform_args_convert_subcommand() {
c.tmp_dir /= c.path_to_output.filename().string() + ".tmp";

if (sc.get_option("--compression-lvl")->empty()) {
c.compression_lvl = c.output_format == "hic" ? 9 : 6;
c.compression_lvl = c.output_format == "hic" ? 10 : 6;
}
}

Expand Down
4 changes: 2 additions & 2 deletions src/hictk/cli/cli_load.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ void Cli::make_load_subcommand() {
"-l,--compression-lvl",
c.compression_lvl,
"Compression level used to compress interactions.\n"
"Defaults to 6 and 9 for .cool and .hic files, respectively.")
"Defaults to 6 and 10 for .cool and .hic files, respectively.")
->check(CLI::Bound(1, 12));

sc.add_option(
Expand Down Expand Up @@ -201,7 +201,7 @@ void Cli::transform_args_load_subcommand() {
c.tmp_dir /= (std::filesystem::path(c.output_path).filename().string() + ".tmp");

if (sc.get_option("--compression-lvl")->empty()) {
c.compression_lvl = c.output_format == "hic" ? 9 : 6;
c.compression_lvl = c.output_format == "hic" ? 10 : 6;
}

// in spdlog, high numbers correspond to low log levels
Expand Down
4 changes: 2 additions & 2 deletions src/hictk/cli/cli_merge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ void Cli::make_merge_subcommand() {
"-l,--compression-lvl",
c.compression_lvl,
"Compression level used to compress interactions.\n"
"Defaults to 6 and 9 for .cool and .hic files, respectively.")
"Defaults to 6 and 10 for .cool and .hic files, respectively.")
->check(CLI::Bound(1, 12));

sc.add_option(
Expand Down Expand Up @@ -181,7 +181,7 @@ void Cli::transform_args_merge_subcommand() {
c.output_format = c.output_file.empty() ? "text" : infer_output_format(c.output_file);

if (sc.get_option("--compression-lvl")->empty()) {
c.compression_lvl = c.output_format == "hic" ? 9 : 6;
c.compression_lvl = c.output_format == "hic" ? 10 : 6;
}

c.tmp_dir /= c.output_file.filename().string() + ".tmp";
Expand Down
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_zoomify.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ void Cli::transform_args_zoomify_subcommand() {
}

if (sc.get_option("--compression-lvl")->empty()) {
c.compression_lvl = c.output_format == "hic" ? 9 : 6;
c.compression_lvl = c.output_format == "hic" ? 10 : 6;
}

c.tmp_dir /= c.path_to_output.filename().string() + ".tmp";
Expand Down

0 comments on commit 22494b4

Please sign in to comment.