Conversation
emma58
left a comment
There was a problem hiding this comment.
This is really exciting! :) A few comments, but none of them should hold this up, I don't think.
| TODO: this is a copy of "Abstract vs Concrete" from Getting Started. | ||
| This should be expanded here. |
There was a problem hiding this comment.
Did you mean to leave this TODO in?
There was a problem hiding this comment.
I guess my real question here is should we duplicate that documentation in two places?
There was a problem hiding this comment.
Yes - I did mean to leave that TODO (as it is not done yet). Ideally, one section will talk about the philosophy of why we support both Abstract and Concrete modeling paradigms, and then we can (maybe) remove abstract from Getting started
| Debugging Models | ||
| ================ | ||
|
|
||
| TODO |
There was a problem hiding this comment.
Is it worth linking to the IDAES docs for the diagnostics toolbox here, at least? Also maybe to the contrib IIS utility?
There was a problem hiding this comment.
Yes. We should write that documentation. I mostly tried not to write any new documentation in this PR - just reorganize things. In this case, this was a new section that we talked about needing to add several times, so it made sense to put in the placeholder as part of this PR.
| Pyomo Tutorial Examples | ||
| ======================= | ||
|
|
There was a problem hiding this comment.
Should this file be deleted? It's empty now, right?
There was a problem hiding this comment.
This file is being deleted. The content was merged into the main doc/OnlineDocs/index.rst
Alternative Solutions documentation add
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3382 +/- ##
==========================================
+ Coverage 81.93% 88.65% +6.71%
==========================================
Files 877 881 +4
Lines 99916 99770 -146
==========================================
+ Hits 81866 88447 +6581
+ Misses 18050 11323 -6727
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
blnicho
left a comment
There was a problem hiding this comment.
I found a few minor typos but otherwise I think this can be merged
| >>> model = pyo.ConcreteModel() | ||
| >>> model.x = pyo.Var() | ||
| >>> model.y = pyo.Var() | ||
| >>> c_list = list(model.component_objects(ctype=pyo.Var, descend_into=True)) | ||
| >>> new = rename_components(model, component_list=c_list, prefix='special_') | ||
| >>> str(new) | ||
| "ComponentMap({'special_x (key=...)': 'x', 'special_y (key=...)': 'y'})" |
There was a problem hiding this comment.
Shouldn't this be in a doctest block?
There was a problem hiding this comment.
It's not necessary. Things that look like Python interactive sessions in the Examples are automatically picked up / tested.
Fixes # .
Summary/Motivation:
This PR reorganizes the Pyomo online documentation to follow a Diataxis-inspired model.
Very little actual documentation changes: this PR was focused on getting the structure / layout correct and is intentionally leaving documentation updates to later (smaller) PRs. That said, there are a few significant documentation (and code) changes (itemized below).
Changes proposed in this PR:
alphaformatliteralinclude::links to be relative to the documentation root directoryConfigDictnumpysoc generationIntEnumimport pyomo.{*}from__init__.pyLegal Acknowledgement
By contributing to this software project, I have read the contribution guide and agree to the following terms and conditions for my contribution: