https://github.com/crytic/roundme

https://github.com/crytic/roundme

Science Score: 13.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.3%) to scientific vocabulary
Last synced: 9 months ago · JSON representation

Repository

Basic Info
  • Host: GitHub
  • Owner: crytic
  • License: agpl-3.0
  • Language: Rust
  • Default Branch: main
  • Size: 202 KB
Statistics
  • Stars: 90
  • Watchers: 2
  • Forks: 7
  • Open Issues: 4
  • Releases: 1
Created over 2 years ago · Last pushed about 2 years ago
Metadata Files
Readme License

README.md

roundme

roundme is a human-assisted rounding analyzer. It helps its operator determine whether an arithmetic operation should round up or down.

Features

  • Recommends whether an arithmetic operation needs to round up or down
  • Generates LaTeX-based reports in PDF

Rules

rounding() is the expected rounding direction for the result (up or down)

  • A + B => rounding(A), rounding(B) (addition does not change the rounding direction)
  • A - B => rounding(A), ! rounding(B) (the rounding direction of the substracted element is inverse of the expected rounding)
  • A * B => rounding(A), rounding(B), rounding(*) (multiplication does not change the rounding direction)
  • A / B => rounding(A), ! rounding(B), rounding(/) (the rounding direction of the denominator is the inverse of the expected rounding)
  • A ** B
    • If A>=1 => rounding(A), rounding(B)
    • If A<1 => rounding(A), ! rounding(B) (if A is below 1, the rounding direction of the exponent is the inverse of the expected rounding)

How to use

  • Run roundme init-sample to generate a default configuration file.
  • Run roundme init to generate user configuration file.
  • Run roundme analyze to analyze the configuration file
  • Run roundme analyze --output-format pdf to generate a PDF (require latexmk)

Running roundme analyze --output-format pdf on the default configuration will generate the following: Example

Configuration

roundme relies on a configuration file: yaml formula: a * b / c round_up: true less_than_one: ["a * b"] # optional greater_than_one: ["c"] # optional - formula contains the formula to be analyze - round_up determines if the result of the formula should round up or down - less_than_one is used for the ** rules (raw string comparison and sensible to space) - greater_than_one is used for the ** rules (raw string comparison and sensible to space)

See the balancer V2 example.

Install

Install with bash cargo install roundme

To install the latest GitHub version bash git clone git@github.com:crytic/roundme.git cd roundme cargo install --path .

Owner

  • Name: Crytic
  • Login: crytic
  • Kind: organization
  • Email: opensource@trailofbits.com
  • Location: New York, NY

Blockchain Security, by @trailofbits

GitHub Events

Total
  • Watch event: 4
  • Fork event: 1
Last Year
  • Watch event: 4
  • Fork event: 1

Issues and Pull Requests

Last synced: over 1 year ago

All Time
  • Total issues: 4
  • Total pull requests: 5
  • Average time to close issues: 2 days
  • Average time to close pull requests: 4 months
  • Total issue authors: 4
  • Total pull request authors: 3
  • Average comments per issue: 0.25
  • Average comments per pull request: 0.4
  • Merged pull requests: 2
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 4
  • Pull requests: 5
  • Average time to close issues: 2 days
  • Average time to close pull requests: 4 months
  • Issue authors: 4
  • Pull request authors: 3
  • Average comments per issue: 0.25
  • Average comments per pull request: 0.4
  • Merged pull requests: 2
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • aviggiano (1)
  • 0xicingdeath (1)
  • tbwebb22 (1)
  • montyly (1)
Pull Request Authors
  • 0xalpharush (4)
  • tarunbhm (3)
  • 0xicingdeath (2)
Top Labels
Issue Labels
enhancement (1)
Pull Request Labels

Dependencies

Cargo.lock cargo
  • 323 dependencies
Cargo.toml cargo
  • cargo-audit 0.18.3 development
  • tempfile 3.3.0 development
  • anyhow 1.0
  • clap 3.0
  • lalrpop-util 0.20.0
  • latex 0.3.1
  • serde 1.0
  • serde_yaml 0.8