<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#0563C1;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:#954F72;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0in;
mso-margin-bottom-alt:auto;
margin-left:0in;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle18
{mso-style-type:personal;
font-family:"Calibri",sans-serif;
color:windowtext;}
span.EmailStyle19
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">Mike,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thank you for the tip. While following this trail I stumbled upon the saveDataFile() function in Cmpl.py, which provides exactly what I needed. The benefit for me using this function as opposed to copying the temp file is that I don’t have
to use debug mode and the filename is predictable (matches my cmpl file, rather than having a random number attached like in debug mode). This allows me to then move or rename as needed for archiving purposes.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks for your assistance. I hope others find this approach helpful.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Best,<o:p></o:p></p>
<p class="MsoNormal">Bhrett<span style="font-size:10.0pt"><o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b>From:</b> Mike Steglich [mailto:mike.steglich@th-wildau.de]
<br>
<b>Sent:</b> Friday, November 17, 2017 1:49 PM<br>
<b>To:</b> Ogden, Bhrett A. <ogdenba@cdmsmith.com><br>
<b>Subject:</b> Re: [Cmpl] PyCMPL: Export CDAT?<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal">Hi Bhrett,<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">PyCmpl writes all temp file into the TMP folder and delete these files after solving the problem. There is a non-documented method Cmpl.debug(mode) in pyCmpl with that this behaviour can be influenced. If your Cmpl object is model then
you can use model.debug(True) before model.solve(). PyCmpl awaits hitting a key and before you do that you can obtain the temp files. <o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">A export function sounds like a good idea. I could send a beta version with that function if the workaround described below is not comfortable.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Cheers,<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Mike<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><br>
Am 17.11.2017 um 19:13 schrieb Ogden, Bhrett A. <<a href="mailto:ogdenba@cdmsmith.com">ogdenba@cdmsmith.com</a>>:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal">I am exploring the possible use of building CMPL into a desktop application, which will have a database as part of the backend. In my application, I would like to leave the problem specification without data. That is to say that I would
have a CMPL file and read data in from the databases in Python. I would then use pyCMPL to add my data and solve the problem. One thing that would be very helpful for archiving model runs would be a way to export a CDAT file that represents the data added
in my pyCMPL code. I have looked through the documentation, and I do not see this feature offered (although I see ways that I could process the data and form the file myself). Is there a built-in way to export a CDAT file that I’m missing? If not, might this
be something that would be included in future versions?<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">Thank you for your hard work on CMPL.<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">Best,<o:p></o:p></p>
<p class="MsoNormal">Bhrett<o:p></o:p></p>
</div>
</blockquote>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal">_______________________________________________<br>
Cmpl mailing list<br>
<a href="mailto:Cmpl@list.coin-or.org">Cmpl@list.coin-or.org</a><br>
<a href="https://urldefense.proofpoint.com/v2/url?u=https-3A__list.coin-2Dor.org_mailman_listinfo_cmpl&d=DwMFaQ&c=NpiPIT1KNSO0vXgGk6ogJQ&r=lti1h6i9rU5mEC99NvhtD9QtmLoHcyEs5V5LTq78EsM&m=T24xJHoyAzQvqC2En8i2oik_-3o666chgVrZGRW5kEc&s=7zpW170zdnkCDDtGZD_pcFBgDbVwoF4OTR5ZyvOCyUc&e=">https://list.coin-or.org/mailman/listinfo/cmpl</a><o:p></o:p></p>
</div>
</blockquote>
</div>
</div>
</body>
</html>