stepup.report.api
Application programming interface for StepUp Report.
add_notes_pdf(path_pdf, path_notes, dest, *, optional=False, resources=None, duration=None)
¶
Add a notes page at every even page of a PDF file.
Parameters:
-
path_pdf(StrPath) –The original PDF document without notes pages.
-
path_notes(StrPath) –A single-page PDF document with a page suitable for taking notes.
-
dest(StrPath) –The output PDF with notes pages inserted, or a directory with a trailing slash. In a directory, the output has the same name as
path_pdf. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
cat_pdf(paths_pdf, dest, *, insert_blank=False, optional=False, resources=None, duration=None)
¶
Concatenate the pages of multiple PDFs into one document.
Parameters:
-
paths_pdf(Collection[StrPath]) –The input PDF files.
-
dest(StrPath) –The concatenated PDF.
-
insert_blank(bool, default:False) –Insert a blank page after a PDF with an odd number of pages. The last page of each PDF is used to determine the size of the added blank page.
-
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
check_hrefs(path_src, *, path_config=None, resources=None, duration=None)
¶
Check hyper references in a Markdown, HTML or PDF file.
Parameters:
-
path_src(StrPath) –The source Markdown, HTML or PDF to check.
-
path_config(StrPath | None, default:None) –The configuration file. Defaults to
${STEPUP_REPORT_CHECK_HREFS_CONFIG}variable orcheck_hrefs.yamlif it is not set. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
compile_latex(path_tex, *, run_bibtex=True, maxrep=5, workdir='./', latex=None, bibtex=None, step_info=None, optional=False, resources=None, duration=None)
¶
Create a step for the compilation of a LaTeX source.
Parameters:
-
path_tex(StrPath) –The main tex source file. This argument may contain environment variables.
-
run_bibtex(bool, default:True) –By default, when bib files are used, BibTeX is invoked. This can be overruled by setting this argument to False, which is useful when recompiling sources with fixed bbl files.
-
maxrep(int, default:5) –The maximum number of repetitions of the LaTeX command in case the aux file keeps changing.
-
workdir(StrPath, default:'./') –The working directory where the LaTeX command must be executed.
-
latex(StrPath | None, default:None) –Path to the LaTeX executable. Note that only PDF-producing LaTeX compilers are supported:
pdflatex,xelatexorlualatex. Defaults to${STEPUP_REPORT_LATEX}variable orpdflatexif the variable is unset. -
bibtex(StrPath | None, default:None) –Path to the BibTeX executable. Defaults to
${STEPUP_REPORT_BIBTEX}variable orbibtexif the variable is unset. -
step_info(StrPath | None, default:None) –A JSON file to which the dependencies of the step are written when the step succeeds, in the format of
dump_step_info()of StepUp Core. It lists the main LaTeX source, the.auxand.pdfoutputs, the files found by scanning the LaTeX sources, including those declared with%REPREP inpand%REPREP out, the bibliography files and the.bblfile. The.bblfile is an output when BibTeX runs and an input otherwise. It also lists the files that LaTeX reports in the.flsfile, such as local class and style files, as far as${STEPUP_PATH_FILTER}retains them. By default, this excludes the files outside${STEPUP_ROOT}, such as those of the LaTeX distribution. Volatile files and the.flsfile itself are not listed. The file is an output of the step, but it does not list itself. Pass it tomake_inventory()of StepUp Data to archive these files, e.g. to send the sources of the document to a journal. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Notes
The LaTeX source is compiled with the sr-compile-latex command,
which can detect dependencies on other files
by scanning for \input, \include, \includegraphics, etc.
Due to the complexity of LaTeX, the dependency scanning is not perfect.
You can manually specify dependencies in the LaTeX source with the following comments:
%REPREP inp inp_path%REPREP out out_path%REPREP vol vol_path
When any of these paths is a relative path,
it is interpreted in the same way as the LaTeX compiler would resolve it.
You can also hide lines from the dependency scanner
by adding %REPREP ignore at the end of a line.
Source code in stepup/report/api.py
163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 | |
compile_tectonic(path_tex, dest=None, *, workdir='./', tectonic=None, keep_deps=None, tectonic_args=(), step_info=None, optional=False, resources=None, duration=None)
¶
Create a step for the compilation of a LaTeX source with Tectonic.
Warning
This feature is only tested with Tectonic 0.17
Support for Tectonic in StepUp Report is experimental. Expect breaking changes in future releases.
Parameters:
-
path_tex(StrPath) –The main LaTeX source file. This argument may contain environment variables.
-
dest(StrPath | None, default:None) –Output directory, with a trailing slash. If
None, the PDF is written in the directory of the LaTeX source. -
workdir(StrPath, default:'./') –The working directory where the LaTeX command must be executed.
-
tectonic(StrPath | None, default:None) –Path to the Tectonic executable. Defaults to
${STEPUP_REPORT_TECTONIC}variable ortectonicif the variable is unset. -
keep_deps(bool | None, default:None) –If
True, the dependency file is kept after the compilation. When not set, thesr-compile-tectoniccommand will use the value of the environment variableSTEPUP_REPORT_TECTONIC_KEEP_DEPSor default toFalseif the variable is not defined. -
tectonic_args(Collection[str], default:()) –Additional arguments for tectonic. The defaults is
${STEPUP_REPORT_TECTONIC_ARGS}, if the environment variable is defined. -
step_info(StrPath | None, default:None) –A JSON file to which the dependencies of the step are written when the step succeeds, in the format of
dump_step_info()of StepUp Core. It lists the main LaTeX source, the PDF, and the local files read by Tectonic, as reported in its dependency file, but not the dependency file itself when it is kept. The file is an output of the step, but it does not list itself. Pass it tomake_inventory()of StepUp Data to archive these files, e.g. to send the sources of the document to a journal. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 | |
compile_typst(path_typ, dest=None, *, inp=(), sysinp=None, resolution=None, workdir='./', typst=None, keep_deps=None, typst_args=(), step_info=None, optional=False, resources=None, duration=None)
¶
Create a step for the compilation of a Typst source.
Warning
This feature is expected to work only with typst 0.15.
Support for Typst in StepUp Report is experimental. Expect breaking changes in future releases. Some limitations include:
- SVG figures with references to external SVG images are not processed correctly. These images are not rendered, neither are they included in the dep file. Tracked upstream in https://github.com/typst/typst/issues/6858.
Parameters:
-
path_typ(StrPath) –The main typst source file. This argument may contain environment variables.
-
dest(StrPath | None, default:None) –Output destination:
None, a directory or a file. For SVG and PNG outputs, this argument must be specified with the desired extension. If the output contains any of{p},{0p}or{t}, the output paths are not known a priori and will be amended. -
inp(StrPath | Collection[StrPath], default:()) –Additional files that are inputs to the typst source, e.g. images or other typst files. Note that these dependencies are detected automatically after the typst compilation, so specifying them here is optional and only improves scheduling efficiency when these inputs are the outputs of other steps.
-
sysinp(dict[str, str | int | float | StrPath] | None, default:None) –A dictionary with the input arguments passed to
typstwith--input key=val. Items are ignored when keys are not strings or when values are not of typestr,int,float,path.Pathoros.PathLike(e.g.pathlib.Path). If a key is not a valid Python identifier, an exception is raised. These parameters are available in the document as#sys.inputs.key. One may also provide an object, which is converted into adictwith thevars()built-in. -
resolution(int | None, default:None) –The resolution of the bitmap in dots per inch (dpi), only relevant for PNG output.
-
workdir(StrPath, default:'./') –The working directory where the LaTeX command must be executed.
-
typst(StrPath | None, default:None) –Path to the Typst executable. Defaults to
${STEPUP_REPORT_TYPST}variable ortypstif the variable is unset. -
keep_deps(bool | None, default:None) –If
True, the dependency file is kept after the compilation. When not set, thesr-compile-typstcommand will use the value of the environment variableSTEPUP_REPORT_TYPST_KEEP_DEPSor default toFalseif the variable is not defined. -
typst_args(Collection[str], default:()) –Additional arguments for typst. The defaults is
${STEPUP_REPORT_TYPST_ARGS}, if the environment variable is defined. -
step_info(StrPath | None, default:None) –A JSON file to which the dependencies of the step are written when the step succeeds, in the format of
dump_step_info()of StepUp Core. It lists the main Typst source, the files ininp, the outputs, and the local files read by Typst, as reported in its dependency file, but not the dependency file itself when it is kept. The file is an output of the step, but it does not list itself. Pass it tomake_inventory()of StepUp Data to archive these files, e.g. to send the sources of the document to a journal. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 | |
convert_inkscape(path_svg, dest=None, *, inkscape=None, inkscape_args=(), step_info=None, optional=False, resources=None, duration=None)
¶
Convert an SVG figure to PDF or PNG, detecting dependencies of the SVG on other files.
Parameters:
-
path_svg(StrPath) –The input SVG figure. It may contain
<image>tags referring to other files included in the figure. -
dest(StrPath | None, default:None) –Output destination:
None, a directory or a file. The output is a PDF file, unlessdestis a file with extension.png. -
inkscape(StrPath | None, default:None) –The path to the inkscape executable. Defaults to
${STEPUP_REPORT_INKSCAPE}variable orinkscapeif the variable is unset. -
inkscape_args(Collection[str], default:()) –Additional arguments to pass to inkscape. E.g.
["-T"]to convert text to glyphs in PDFs. Depending on the extension of the output, the default is${STEPUP_REPORT_INKSCAPE_PDF_ARGS}or${STEPUP_REPORT_INKSCAPE_PNG_ARGS}, if the environment variable is defined. -
step_info(StrPath | None, default:None) –A JSON file to which the dependencies of the step are written when the step succeeds, in the format of
dump_step_info()of StepUp Core. It lists the SVG file, the output and the files included in the figure. The file is an output of the step, but it does not list itself. Pass it tomake_inventory()of StepUp Data to archive these files. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Notes
Images and other files referenced by the SVG are detected automatically and amended as inputs of the step. This scan may be a bit slow in case of large files.
Source code in stepup/report/api.py
552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 | |
convert_markdown(path_md, dest=None, *, paths_css=(), optional=False, resources=None, duration=None)
¶
Convert a markdown to HTML.
Parameters:
-
path_md(StrPath) –The markdown input file.
-
dest(StrPath | None, default:None) –Output destination:
None, a directory or a file. -
paths_css(StrPath | Collection[StrPath], default:()) –Path or multiple paths of a local CSS file, or a list of multiple such paths, to be included in the HTML header. Note that one may also specify CSS file in the markdown header. Defaults to
${STEPUP_REPORT_MARKDOWN_CSS}if the variable is set, which is interpreted as a list of files separated by:, or by;on Windows. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
convert_weasyprint(path_html, dest=None, *, weasyprint=None, step_info=None, optional=False, resources=None, duration=None)
¶
Convert a HTML document to PDF with WeasyPrint.
WeasyPrint is not installed with StepUp Report. See the installation instructions for how to install it.
Parameters:
-
path_html(StrPath) –The HTML input file.
-
dest(StrPath | None, default:None) –Output destination:
None, a directory or a file. -
weasyprint(StrPath | None, default:None) –The path to the weasyprint executable. Defaults to
${STEPUP_REPORT_WEASYPRINT}variable orweasyprintif the variable is unset. -
step_info(StrPath | None, default:None) –A JSON file to which the dependencies of the step are written when the step succeeds, in the format of
dump_step_info()of StepUp Core. It lists the HTML file, the PDF, and the images and style sheets used by the HTML file. The file is an output of the step, but it does not list itself. Pass it tomake_inventory()of StepUp Data to archive these files. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
diff_latex(path_old, path_new, dest, *, latexdiff=None, latexdiff_args=None, optional=False, resources=None, duration=None)
¶
Create a step to run latexdiff.
Parameters:
-
path_old(StrPath) –The old tex or bbl source.
-
path_new(StrPath) –The new tex or bbl source.
-
dest(StrPath) –The diff output tex or bbl, or a directory with a trailing slash. In a directory, the output has the same name as
path_new. A file must have the same extension aspath_new. -
latexdiff(StrPath | None, default:None) –Path of the latexdiff executable. Defaults to
${STEPUP_REPORT_LATEXDIFF}variable orlatexdiffif the variable is unset. -
latexdiff_args(Collection[str] | None, default:None) –Additional arguments for latexdiff. Defaults to the value of
${STEPUP_REPORT_LATEXDIFF_ARGS}, split like a shell command. If this variable is unset, the following default is used:--append-context2cmd=abstract,supplementary,dataavailability,funding, \ authorcontributions,conflictsofinterest,abbreviationsThe option
--no-labelis always added because it is needed to make the file reproducible. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
flatten_latex(path_tex, dest=None, *, optional=False, resources=None, duration=None)
¶
Flatten structured LaTeX source files (substitute \input and friends by their content).
Parameters:
-
path_tex(StrPath) –The main tex file to be converted.
-
dest(StrPath | None, default:None) –Output destination:
None, a directory or a file. WhenNone, the output is{stem}-flat.texin the directory ofpath_tex. In a directory, the output has the same name aspath_tex. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
nup_pdf(path_pdf, dest, *, nrow=None, ncol=None, margin=None, page_format=None, optional=False, resources=None, duration=None)
¶
Put multiple pages per sheet using a fixed layout.
Parameters:
-
path_pdf(StrPath) –The original PDF document (with normal pages).
-
dest(StrPath) –The output PDF (with multiple pages per sheet), or a directory with a trailing slash. In a directory, the output has the same name as
path_pdf. -
nrow(int | None, default:None) –The number of rows on each output sheet. The default is
${STEPUP_REPORT_NUP_NROW}or 2 if the variable is not set. -
ncol(int | None, default:None) –The number of columns on each output sheet. The default is
${STEPUP_REPORT_NUP_NCOL}or 2 if the variable is not set. -
margin(float | None, default:None) –The margin in mm between the pages on each sheet. (Also used as sheet margin.) The default is
${STEPUP_REPORT_NUP_MARGIN}or 10.0 if the variable is not set. -
page_format(str | None, default:None) –The output page format. The default is
${STEPUP_REPORT_NUP_PAGE_FORMAT}or A4-L if the variable is not set. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
raster_pdf(path_pdf, dest, *, resolution=None, quality=None, optional=False, resources=None, duration=None)
¶
Render the pages of a PDF into a new PDF with JPEG bitmaps, or into PNG files.
Parameters:
-
path_pdf(StrPath) –The input PDF file.
-
dest(StrPath) –A directory with a trailing slash or a file. In a directory, the output is a PDF with the same name as
path_pdf. The output is a PDF file, unlessdestis a file with extension.png. A PNG file is written for every page, and its name may contain the placeholders{p}(the page number),{0p}(the page number padded with zeros) and{t}(the number of pages), as in the output ofcompile_typst(). One of{p}and{0p}is required when the PDF has more than one page. With placeholders, the names of the PNG files are only known when the step runs, so they are amended as outputs of the step. -
resolution(int | None, default:None) –The resolution of the bitmap in dots per inch (dpi). The default value is taken from
${STEPUP_REPORT_RASTER_RESOLUTION}or 100 if the variable is not set. -
quality(int | None, default:None) –The JPEG quality of the bitmap, only for PDF output. The default value is taken from
${STEPUP_REPORT_RASTER_QUALITY}or 50 if the variable is not set. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
sanitize_bibtex(path_bib, dest=None, *, path_aux=None, path_config=None, optional=False, resources=None, duration=None)
¶
Sanitize a BibTeX file.
Parameters:
-
path_bib(StrPath) –Path to the BibTeX file to be sanitized.
-
dest(StrPath | None, default:None) –If given, the cleaned-up BibTeX file is written to this file, or to a file with the same name in this directory, when it has a trailing slash. You can manually copy it back to the original if you approve of the cleanup. If not given, the original BibTeX file is overwritten when it needs a cleanup, which will drain the scheduler. You then check if the updated version is correct and rerun the build to approve.
-
path_aux(StrPath | None, default:None) –Path to the LaTeX aux file, if any. This is used to detect unused or missing citations.
-
path_config(StrPath | None, default:None) –The YAML configuration file for the
sr-bibsanescript. -
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.
Source code in stepup/report/api.py
1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 | |
unplot(path_svg, dest=None, *, optional=False, resources=None, duration=None)
¶
Convert a plot back to data.
Parameters:
-
path_svg(StrPath) –The SVG file with paths to be converted back.
-
dest(StrPath | None, default:None) –An output directory or file.
-
optional(bool, default:False) –If
True, the step is only executed when needed by other steps. -
resources(dict[str, int] | str | None, default:None) –Named resources required to run this step, e.g.
{"gpu": 1}. Seestepup.core.api.step()for details. -
duration(float | None, default:None) –An initial estimate of the step’s wall time in seconds. See
stepup.core.api.step()for details.
Returns:
-
step_info–Holds relevant information of the step, useful for defining follow-up steps.