Skip to main content

A report generation package for results of Monaco 2018 Racing

Project description

Formula 1 Monaco 2018 Racing Report Generator

This Python package provides a tool for generating reports based on the start and end data of the best lap for each racer of Formula 1 - Monaco 2018 Racing during the first stage of the qualification (Q1).

Installation

To use the package, you need to install it first. You can do this using pip:

</code></pre>
<h2>Usage</h2>
<p>The package provides a command-line interface with several options.</p>
<h3>Generating a Report</h3>
<p>You can generate a report for the first 20 minutes of the Monaco 2018 Racing by providing the path to the folder containing the data files. The <code>--asc</code> or <code>--desc</code> flag allows you to specify the sorting order (default is ascending).</p>
<pre lang="bash"><code>report.py --files <folder_path> [--asc | --desc]

Driver Statistics

To get statistics about a specific driver, use the --driver option along with the folder path.

report.py --files <folder_path> --driver "Sebastian Vettel"

Package Structure

The package consists of the following components:

  • Record Class: Represents a racer record with start and end times.
  • FileNotFound Exception: Raised when a specified file is not found.
  • ReportInvalidOrder Exception: Raised for an invalid sorting order in the report.
  • build_report Function: Compiles a report summarizing valid and invalid records.
  • print_report Function: Prints a formatted report based on ordered results.
  • cli Function: Parses command-line arguments and orchestrates the report generation process.

Example

import report.py
#(update later)
# Command-line interface
args = formula1_report.Record.cli()

# Build the report
good_records, bad_records = formula1_report.Record.build_report(args.files, args.sort)

# Filter records if a specific driver is provided
if args.driver:
    good_records = [rec for rec in good_records if rec.driver == args.driver]
    bad_records = [rec for rec in bad_records if rec.driver == args.driver]

# Print the report
print(report.Record.print_report(good_records, bad_records))

License

This package is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

report_volo-0.0.8.tar.gz (10.0 kB view details)

Uploaded Source

Built Distribution

report_volo-0.0.8-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file report_volo-0.0.8.tar.gz.

File metadata

  • Download URL: report_volo-0.0.8.tar.gz
  • Upload date:
  • Size: 10.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.4

File hashes

Hashes for report_volo-0.0.8.tar.gz
Algorithm Hash digest
SHA256 9a4f8c47f6ae1e1fbbbf5f74ad87032c8aafae9c1dcd40beae0bf6bf8d12738a
MD5 922afb2dcbf93abdd336c62578afe75b
BLAKE2b-256 dc420154a3f120cafbb9e05f32ee046173f04222f99243ae92dc0a955b5963e4

See more details on using hashes here.

File details

Details for the file report_volo-0.0.8-py3-none-any.whl.

File metadata

  • Download URL: report_volo-0.0.8-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.4

File hashes

Hashes for report_volo-0.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 7956ab2267e4e48e6aef86e4d787a94a9698e56594bc68231135721715e8c5ee
MD5 9ccf563f0d334ec2cf8fdcce7fd14c11
BLAKE2b-256 2d5d4436f9b9f951560f2bb736aefa31095fd5dd3e3fec22ccc7fe190a3665b6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page