Генератор отчета для html

numerous Report Generator

A python package focused on enabling you to create beautiful and powerful html reports with great ease. You can use the reports to document your work and showcase your data, even generating these automitically with your analysis code already implemented in python.

This package exposes a simple library to create a report, adding your sections, figures and tables or even just directly html divs with your own custom html code.

When you have added your content to the report you can save it to a stand-alone html file you can share with anyone.

We have provided you with a first template that you can modify to your needs. Soon we will publish a guide on how to change basic things in it — for instance the logo file.

Installation

The package numerous report generator can be installed with:

Quick start

Here is a simple example to get you started once you have installed the package:

           Please see CONTRIBUTING.md for details on how to contribute.

Источник

numerous Report Generator

A python package focused on enabling you to create beautiful and powerful html reports with great ease. You can use the reports to document your work and showcase your data, even generating these automitically with your analysis code already implemented in python.

This package exposes a simple library to create a report, adding your sections, figures and tables or even just directly html divs with your own custom html code.

When you have added your content to the report you can save it to a stand-alone html file you can share with anyone.

We have provided you with a first template that you can modify to your needs. Soon we will publish a guide on how to change basic things in it — for instance the logo file.

Installation

The package numerous report generator can be installed with:

Quick start

Here is a simple example to get you started once you have installed the package:

           Please see CONTRIBUTING.md for details on how to contribute.

Источник

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

s-reaungamornrat/html_report_generator

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Sign In Required

Please sign in to use Codespaces.

Launching GitHub Desktop

If nothing happens, download GitHub Desktop and try again.

Launching GitHub Desktop

If nothing happens, download GitHub Desktop and try again.

Launching Xcode

If nothing happens, download Xcode and try again.

Launching Visual Studio Code

Your codespace will open once ready.

There was a problem preparing your codespace, please try again.

Latest commit

Git stats

Files

Failed to load latest commit information.

README.md

A simple generator developed for reporting results from (large-scale) experimental studies in a form of a sortable table. The generator receives a json file describing experimental results to be displayed; thus column headers and contents can be designed and tailored to individual experiments. It supports 2D images, videos, and quantitative measurements. The format of json file compatible with the generator is described below.

Section 1. Getting Started

The generator was developed using python 3.6.5 and pandas 0.23.0 to generate an html table. For conda users, you can install the packages using a command

conda install python=3.6.5 pandas=0.23.0 

or create a new conda environment using .yml files provided in ./enviroments/ using a command

conda env create -f environment.yml 

Currently only a yml file for Windows is provided and that for Linux will be added soon.

A generated HTML report uses a style defined in ./styles/staticpages.css . You can, of course, change the style and appearance of your report by copying this .css and modifying it according to your liking, perhaps to change the size of images and/or video, the background color, font styles and colors, etc. To use your .css , place your .css in ./styles/ and pass it as input the generator as described in Section 2.

A json file is used as an input to describe the format of your desired HTML table and paths to experimental results to be displayed. The generator supports quantitative measurements and media (i.e., 2D images and videos). Here we assume that your quantitative measurements are stored in one .csv file on which each column represents each metric measure separated by a comma (,). An extra column with the pre-defined, fixed header measure_uid need to be present; each element in this column is an ID of each experiment, implying that all related images and/or videos resulted from the experiment shared the same ID. measure_uid is used internally as a key to link each measurement to each relevant media to be displayed in the same row of the HTML table. An example of a csv file reporting target registration error, normalized cross correlation, and Jacobian determinants of displacement fields is

measure_uid,TRE, NCC, JD 1223323,0.223,0.845,4.678 1223326,0.593,0.707,3.086 1223327,0.432,0.789,3.976 . 

The json file contains two name/value pairs:

"experiment_title":"your experiment name" "measurements":"path/to/csv-file" 

The latter is the csv file described above. Aside from these two pairs, the json file contains any number of name/object pairs. An object in each name/object pair describe media involving with each experiment and the name is just an arbitrary ID for the result. An example result from a rigid registration could be

"AnyID": < "fixed":<>"moving":<> "measure_uid":"alphanumeric_characters" "result_img":<> "video":<> > 

This is one json object. The value of «measure_id» is some alphanumeric characters matching that of a quanititative measure recorded in the corresponding .csv file. Values of other members of an object are not <> and will be described below. (We ignore it for now for clarity and simplicity.) These members of a json object, except «measure_id» , (named «fixed» , «moving» , «result_img» , «video» ) are not required and can be changed according to your requirement. Hence, your object could be

"BARBAR": < "true_label":<>"measure_uid":"alphanumeric_characters" "estimated_label1":<> "estimated_label2":<> "estimated_label3":<> > 

where «estimated_label1» , «estimated_label2» , «estimated_label3» the three most likely labels for an object in a given test image.

Now we define values of members of an object, which is presented as <> above. Each member is by itself a json object and required to contain the following three name/value pairs:

The value of «header» is the name of the column or the column header. The value of «type» is either «image» or «video» , but not both, and the value of «path» is path\to\image or path\to\video. We recommend using absolute paths if you want to separate the report generator code from your experimental results. Hence, the AnyID object above should look like

"AnyID": < "fixed":< "header":". ", "type":". ", "path":". " >"moving": < "header":". ", "type":". ", "path":". " >"measure_uid":"alphanumeric_characters" "result_img": < "header":". ", "type":". ", "path":". " >"video": < "header":". ", "type":". ", "path":". " >> 

In a nutshell, a json file should follow the following format

 < "experiment_title":"your experiment name" "measurements":"path/to/csv-file" "BARBAR1":< "true_label":< "header":". ", "type":". ", "path":". " >"measure_uid":"alphanumeric_characters" "estimated_label1": < "header":". ", "type":". ", "path":". " >"estimated_label2": < "header":". ", "type":". ", "path":". " >"estimated_label3": < "header":". ", "type":". ", "path":". " >> "BARBAR2": < "true_label":< "header":". ", "type":". ", "path":". " >"measure_uid":"alphanumeric_characters" "estimated_label1": < "header":". ", "type":". ", "path":". " >"estimated_label2": < "header":". ", "type":". ", "path":". " >"estimated_label3": < "header":". ", "type":". ", "path":". " >> . > 

An example json file can be found in ./examples/ .

Section 2. Generating a Report

The package includes example ‘results’ to be displayed in ./examples/ . The associated json file is ./examples/results.json and the generated HTML report is ./examples/report.html . Assuming that you are at the package folder, to reproduce the report, use the following command

> python html_report.py ./examples/results.json ./examples/report_blue.html 

The script requires two input and one optional input in the following format

> python html_report.py /path/to/input.json /path/to/report.html [css_file] 

In cases that you have your own css style file in ./styles/ and want to use it, use the following command

> python html_report.py /path/to/input.json /path/to/report.html css_filename 

Источник

Читайте также:  Php fatal error detected windows 10
Оцените статью