Reports

Methods to generate optimization reports.

dnachisel.reports.optimization_reports.write_no_solution_report(target, problem, error, file_content=None, file_path=None)[source]

Write a report on incompatibility found in the problem’s constraints.

The report comprises a PDF of plots of the sequence (global constraints, local constraints around the problem) and an annotated genbank.

Parameters
target

Either a path to a folder, or a path to a zip archive, or “@memory” to return raw data of a zip archive containing the report.

problem

A DnaOptimizationProblem

error

A NoSolutionError (carries a message and a location)

dnachisel.reports.optimization_reports.write_optimization_report(target, problem, project_name='unnamed', plot_figure=True, constraints_evaluations=None, objectives_evaluations=None, figure_width=20, max_features_in_plots=300, file_path=None, file_content=None)[source]

Write an optimization report with a PDF summary, plots, and genbanks.

Parameters
target

Path to a directory or zip file, or “@memory” for returning raw data of a zip file created in-memory.

problem

A DnaOptimizationProblem to be solved and optimized

project_name

Name of the project that will appear on the PDF report

constraints_evaluations

Precomputed constraints evaluations. If None provided, they will be computed again from the problem.

objectives_evaluations

Precomputed objectives evaluations. If None provided, they will be computed again from the problem.

figure_width

Width of the report’s figure, in inches. The more annotations there will be in the figure, the wider it should be. The default should work for most cases.

max_features_in_plots

Limit to the number of features to plot (plots with thousands of features may take ages to plot)

file_path

Path to the file from which the problem was created