{ "info": { "author": "Anne Mulhern", "author_email": "amulhern@redhat.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 2 - Pre-Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)", "Operating System :: POSIX :: Linux", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Software Development :: Libraries", "Topic :: System :: Hardware", "Topic :: System :: Operating System Kernels :: Linux" ], "description": ".. image:: https://secure.travis-ci.org/mulkieran/justbytes.png?branch=master\n :target: http://travis-ci.org/mulkieran/justbytes\n\nJustbytes\n========\n\nJustbytes is a module for handling computation with\naddress ranges expressed in bytes. Its principle feature is a Range class from\nwhich can be constructed Range objects which represent a precise and finite\naddress range in bytes. Various arithmetic operations are defined for Range\nobjects.\n\nIts sole purpose is the representation of real address ranges on real\nmachines. For that reason, it does not allow powers of ranges, imprecise\nranges, or non-finite ranges. In order that the\nusual laws of arithmetic can be maintained, it does allow fractional ranges.\n\n\nPractical Computing with Address Ranges\n---------------------------------------\n\nWhen computing with address ranges, the numeric value can be viewed as a\nlogical, rather than a physical, quantity. That is, unlike, e.g., mass or\nlength, which are quantities which must be measured with a measuring instrument\nwhich has some built-in imprecision, an address range\nis a quantity that is not measured, but is known precisely.\nThis precision arises because the number represents not as much an amount of\nmemory as a number of addressable, byte-size, locations in memory.\n\nConsequently, computations such as addition of two Ranges, and conversion\nbetween different magnitudes of bytes, i.e., from MiB to GiB, must be done\nprecisely. The underlying implementation must therefore use a precise\nrepresentation of the number of bytes. Floating point numbers, which are\nfrequently the preferred type for the representation of physical\nquantities, are disallowed by this requirement.\n\nOperations\n----------\nThis module does not accomodate multi-dimensionality of address ranges.\nConsequently, multiplying one Range object by another Range object will cause\nan error to be raised, since bytes^2 is not representable by the module.\nFor most uses any operation which would yield a multi-dimensional quantity\nis not useful. There are no plans to adapt this package so that it\ncan accomodate multi-dimensionality of address ranges.\n\nNumerous computations with address ranges are nonsensical. For example, 2\nraised to a power which is some address range, is a meaningless computation.\nAll such operations cause an error to be raised.\n\nSome computations with precise, finite, values may yield irrational results.\nFor example, while 2 is rational, its square root is an irrational number.\nThere is no allowed operation on Range objects which can result in an\nirrational Range value. It turns out that all such operations are either\nnonsensical or would result in a value with an unrepresentable type.\n\nThe result type of operations is a Range, where appropriate, or a subtype of\nRational, where a numeric value is appropriate.\n\nFloating Point Numbers\n----------------------\nIt is not possible to use floating point numbers or Decimal in computations\nwith Ranges. Where a fractional quantity is desired, use Fraction objects.\nThus, Range(0) * 1.2 and Range(0) * Decimal(\"1.2\") raise an exception, but\nRange(0) * Fraction(\"1.2\") is acceptable.\n\nComputing the Representation of a Range\n---------------------------------------\nThe representation of a Range is computed according to a specified\nconfiguration. In the default configuration, the representation uses IEC\nrather than SI units.\n\nThe representation of a Range is not a string, but a structured representation\nof the precise value, as well as the relationship of the representation to\nthe actual value.\n\nThis representation is exposed to clients of the library, which may use it\nin any way.\n\nDisplaying Ranges\n----------------\nThe Range class also has standard methods for the representation of Range\nobjects as str objects.\n\nThe str representation can also be configured. The manipulation of the\nrepresentation to form a str object is abstracted from the rest of the source\nto emphasize that clients of the package may choose to represent address ranges\nin any manner they choose.\n\nRepresenting Units\n------------------\nThe size module supplies a set of named prefixes for both SI and binary units,\nfor all non-fractional prefixes. Fractional prefixes are not defined.\n\nConstructing Ranges Programatically\n----------------------------------\nNew Range objects can be constructed from Range objects, numeric values, e.g.,\nint or Fraction, or strings which represent such numeric values.\nstrings may be used to represent fractional quantities, e.g., \"1.2\", but\nfloats and Decimals are disallowed.\n\nThe constructor takes an optional units specifier, which defaults to bytes\nfor all numeric values, and to None for Range objects. The type of the\nunit specifier is a named prefix supplied by the size module or a Range object.\n\nErrors\n------\nAll errors raised by justbytes operations are subtypes of the RangeError class.\n\nMemory Consumption and Bandwidth vs. Address Ranges\n---------------------------------------------------\nMemory consumption, e.g., by a process during execution on a specified\nworkload, is a quantity, that like address ranges, is specified in\nbytes. However, memory consumption is simply a measurement of the amount of\na phsyical quantity consumed. When bytes are used only to represent memory\nconsumption, computations do not generally require the special handling\nsupplied by this library. Generally, measurement of memory consumption can\nbe treated like any other physical quantity. The same reasoning applies to\nbandwidth. For a physical analogy, one can imagine memory consumption to be\nanalogous to volume, e.g., litres, and bandwidth to be analogous to flow,\ne.g., litres per minute.\n\nUser Input\n----------\nThis package does not handle arbitrary user input. It is expected that the\nclient will transform any input, from whatever source, into a number and an\noptional unit specification which can be passed directly to the Range\nconstructor.\n\nAlternative Packages\n--------------------\nIf you are interested in computing in Python with physical, rather than\nlogical, quantities, you should consult the pint package:\nhttp://pint.readthedocs.org.", "description_content_type": "", "docs_url": "https://pythonhosted.org/justbytes/", "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://pythonhosted.org/justbytes/", "keywords": "", "license": "LGPLv2+", "maintainer": "", "maintainer_email": "", "name": "justbytes", "package_url": "https://pypi.org/project/justbytes/", "platform": "Linux", "project_url": "https://pypi.org/project/justbytes/", "project_urls": { "Homepage": "http://pythonhosted.org/justbytes/" }, "release_url": "https://pypi.org/project/justbytes/0.12/", "requires_dist": null, "requires_python": "", "summary": "computing with and displaying bytes", "version": "0.12" }, "last_serial": 5129629, "releases": { "0.10": [ { "comment_text": "", "digests": { "md5": "24d857f208128fc5ab3ed559122eb527", "sha256": "cba2f97ea7eecf4633221ef6da9abfa07ef16db8c552ed4a4eb81f7d5c4cd90e" }, "downloads": -1, "filename": "justbytes-0.10.tar.gz", "has_sig": false, "md5_digest": "24d857f208128fc5ab3ed559122eb527", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 66953, "upload_time": "2016-08-02T13:07:31", "url": "https://files.pythonhosted.org/packages/9f/34/d46b2eff67b473c3cdcdd922efd7fddf008bdd1eff18b59a16223ae43c10/justbytes-0.10.tar.gz" } ], "0.11": [ { "comment_text": "", "digests": { "md5": "7e70ec1dd76d4d9231d6b9c0089e8760", "sha256": "b8cb780db091d3f766283597c050a167ecf2039266b5ceb786206e7b34337fe4" }, "downloads": -1, "filename": "justbytes-0.11.tar.gz", "has_sig": false, "md5_digest": "7e70ec1dd76d4d9231d6b9c0089e8760", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 38839, "upload_time": "2017-12-12T15:58:32", "url": "https://files.pythonhosted.org/packages/bb/2d/1a65cc59265342835c1fb8835493995de771dc1271327f11604527755eb7/justbytes-0.11.tar.gz" } ], "0.12": [ { "comment_text": "", "digests": { "md5": "fc1a48826ddd34b0b06560253a78b74b", "sha256": "8b4eb8dacee7f76be45de7ebe46322108f6fb2b7def4196d36b49917d64fb89f" }, "downloads": -1, "filename": "justbytes-0.12.tar.gz", "has_sig": false, "md5_digest": "fc1a48826ddd34b0b06560253a78b74b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28425, "upload_time": "2019-04-11T15:43:50", "url": "https://files.pythonhosted.org/packages/0e/c9/2705dac7977e8933df70ba9791fb861905cf1a7750d3c183d139c14e3bc8/justbytes-0.12.tar.gz" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "d451f6a07f05c95a47870dc34aa97c20", "sha256": "e66a785348e93780de4545fc1c4d0e6372efe44f518cdf2d284870d440d17b46" }, "downloads": -1, "filename": "justbytes-0.4.tar.gz", "has_sig": false, "md5_digest": "d451f6a07f05c95a47870dc34aa97c20", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 30008, "upload_time": "2015-12-07T19:34:22", "url": "https://files.pythonhosted.org/packages/bf/73/db94f6815265396fe93af45132593b20858f5023d52d6ae05f6a02549ec1/justbytes-0.4.tar.gz" } ], "0.5": [ { "comment_text": "", "digests": { "md5": "159b73bdd80c4fb70ca6aef77075ef43", "sha256": "f8ae0cf87b8c77f45a7fec65c1a04051033079aad3c459be60f0c19d7608914a" }, "downloads": -1, "filename": "justbytes-0.5.tar.gz", "has_sig": false, "md5_digest": "159b73bdd80c4fb70ca6aef77075ef43", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 62921, "upload_time": "2016-03-15T21:32:57", "url": "https://files.pythonhosted.org/packages/fb/43/3b977c127c04a9cfa1c8ec3709430987c988a8b7fe4e934a458bb801a210/justbytes-0.5.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "872d2e2837fb2dcda8a925f94976bd38", "sha256": "c590e1f0808730316081a2582ed3c60cc3617732e0b2c20fe753072891f15641" }, "downloads": -1, "filename": "justbytes-0.6.tar.gz", "has_sig": false, "md5_digest": "872d2e2837fb2dcda8a925f94976bd38", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 42515, "upload_time": "2016-03-23T13:01:00", "url": "https://files.pythonhosted.org/packages/f1/c1/4311d942a51372ff4d71a1c8fe712d9b4a42d5f1bd1ba3d11df96e0310fe/justbytes-0.6.tar.gz" } ], "0.7": [ { "comment_text": "", "digests": { "md5": "5f69189cfe7b73c0d00aef8aa2d5e7d3", "sha256": "22e8a4c94c0dacfaaab6798febb1d75c358cbd839269fc12b2002f6d3e7748e7" }, "downloads": -1, "filename": "justbytes-0.7.tar.gz", "has_sig": false, "md5_digest": "5f69189cfe7b73c0d00aef8aa2d5e7d3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 72591, "upload_time": "2016-04-15T17:38:29", "url": "https://files.pythonhosted.org/packages/ff/fc/ffaca93add30d274cc5053ae5adf80e66574f49972a93ba1ec31765d9c15/justbytes-0.7.tar.gz" } ], "0.8": [ { "comment_text": "", "digests": { "md5": "4c820bd19022f7cab9b6f2a94eb3048b", "sha256": "1a26cce837f4cfd15007610222b269289ef809091e437d47453c71bdca47a92b" }, "downloads": -1, "filename": "justbytes-0.8.tar.gz", "has_sig": false, "md5_digest": "4c820bd19022f7cab9b6f2a94eb3048b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 71953, "upload_time": "2016-05-09T14:22:56", "url": "https://files.pythonhosted.org/packages/12/79/58b72c604d64b1a9c04dbbfd37b0bbea5faedec1ce01e1b53f29abd4a086/justbytes-0.8.tar.gz" } ], "0.9": [ { "comment_text": "", "digests": { "md5": "1e1e4b0294d6c6c02498349a50673f02", "sha256": "48cda8dd1b1dc548495203b5f7ad93d934a97be73b5dfed77a386d917d129c5a" }, "downloads": -1, "filename": "justbytes-0.9.tar.gz", "has_sig": false, "md5_digest": "1e1e4b0294d6c6c02498349a50673f02", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 70795, "upload_time": "2016-05-16T15:38:48", "url": "https://files.pythonhosted.org/packages/1d/27/c55d97057e4dd1d4cf8b9f5dc5fb95aa2bbfdad993537b5f1f70452cd3e9/justbytes-0.9.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "fc1a48826ddd34b0b06560253a78b74b", "sha256": "8b4eb8dacee7f76be45de7ebe46322108f6fb2b7def4196d36b49917d64fb89f" }, "downloads": -1, "filename": "justbytes-0.12.tar.gz", "has_sig": false, "md5_digest": "fc1a48826ddd34b0b06560253a78b74b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28425, "upload_time": "2019-04-11T15:43:50", "url": "https://files.pythonhosted.org/packages/0e/c9/2705dac7977e8933df70ba9791fb861905cf1a7750d3c183d139c14e3bc8/justbytes-0.12.tar.gz" } ] }