snakemake.common.bytesto

snakemake.common.bytesto(bytes, to, bsize=1024)[source]

convert bytes to megabytes. bytes to mb: bytesto(bytes, ‘m’) bytes to gb: bytesto(bytes, ‘g’ etc. From https://gist.github.com/shawnbutts/3906915