Skip to main content

fitrate

Calculate the length of the sides that fit into the limited volume

Test Coverage Package version


Documentation:

Demo:


fitrate

Requirements

Python 3.6+

Installation

$ pip3 install fitrate

Example

from fitrate import contain

print(contain((200, 200), 60000))
# (244, 244)

print(contain((400, 300), 60000))
# (282, 212)

# -----------

from fitrate import scale-down

print(scale-down((200, 200), 60000))
# (200, 200)

print(scale-down((400, 300), 60000))
# (282, 212)

— 🎞️ —

fitrate is licensed under the terms of the MIT license.

Release files for fitrate 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fitrate 1.0.0
File Size Uploaded
fitrate-1.0.0.tar.gz 3.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for fitrate 1.0.0
File Interpreter ABI Platform
fitrate-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 6.7 kB

Release files / fitrate-1.0.0.tar.gz

Download URL fitrate-1.0.0.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
dbe7f3b050131fb8d91b32f4a3e8a02cfaf2fc7bfc3d31a1f8af993e8bbb22c1
BLAKE2b-256 checksum
How to use checksums
769ea4507ab946920c25208225ec471a050c2430c177845b5a36b2be0ae68e45
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.10 CPython/3.8.5 Linux/5.4.0-1025-azure

Release files / fitrate-1.0.0-py3-none-any.whl

Download URL fitrate-1.0.0-py3-none-any.whl
Size 3.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d7066a0fc7260e2d3b81e909827401c4b21a1776c1d4ef7c4e725b994563b296
BLAKE2b-256 checksum
How to use checksums
6aba2e28aea2d808f64073dafbada976d2243e03395532f1a4f4729f18bf698a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.10 CPython/3.8.5 Linux/5.4.0-1025-azure

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page