doc-exports/docs/modelarts/api-ref/modelarts_03_0086.html

400 lines
44 KiB
HTML

<a name="modelarts_03_0086"></a><a name="modelarts_03_0086"></a>
<h1 class="topictitle1">Updating Service Configurations</h1>
<div id="en-us_topic_0130045990_body1536314051452"><div class="section" id="modelarts_03_0086__en-us_topic_0130045990_section15493132575920"><h4 class="sectiontitle">Function</h4><p id="modelarts_03_0086__en-us_topic_0130045990_p185143185919">This API is used to update configurations of a model service. It can also be used to start or stop a service.</p>
</div>
<div class="section" id="modelarts_03_0086__en-us_topic_0130045990_section181341535122619"><h4 class="sectiontitle">URI</h4><p id="modelarts_03_0086__en-us_topic_0130045990_p28751615549">PUT /v1/{project_id}/services/{service_id}</p>
<div class="p" id="modelarts_03_0086__en-us_topic_0130045990_p14336111611503"><a href="#modelarts_03_0086__en-us_topic_0130045990_table10624434011">Table 1</a> describes the required parameters.
<div class="tablenoborder"><a name="modelarts_03_0086__en-us_topic_0130045990_table10624434011"></a><a name="en-us_topic_0130045990_table10624434011"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0086__en-us_topic_0130045990_table10624434011" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters</caption><thead align="left"><tr id="modelarts_03_0086__en-us_topic_0130045990_row13653412406"><th align="left" class="cellrowborder" valign="top" width="18%" id="mcps1.3.2.3.2.2.5.1.1"><p id="modelarts_03_0086__en-us_topic_0130045990_p8665404020">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.2.3.2.2.5.1.2"><p id="modelarts_03_0086__en-us_topic_0130045990_p46614184018">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="12%" id="mcps1.3.2.3.2.2.5.1.3"><p id="modelarts_03_0086__en-us_topic_0130045990_p668154124018">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="55.00000000000001%" id="mcps1.3.2.3.2.2.5.1.4"><p id="modelarts_03_0086__en-us_topic_0130045990_p469204194016">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0086__en-us_topic_0130045990_row1797617864917"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p8780885181639">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.3.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p40163046181639">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="12%" headers="mcps1.3.2.3.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p31981288181639">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.00000000000001%" headers="mcps1.3.2.3.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p40347522181639">Project ID. For details about how to obtain the project ID, see <a href="modelarts_03_0147.html">Obtaining a Project ID</a>.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row870174164011"><td class="cellrowborder" valign="top" width="18%" headers="mcps1.3.2.3.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p372348400">service_id</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.2.3.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p19736411406">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="12%" headers="mcps1.3.2.3.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p174643403">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.00000000000001%" headers="mcps1.3.2.3.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p575194174011">Service ID</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<div class="section" id="modelarts_03_0086__en-us_topic_0130045990_section71456147333"><h4 class="sectiontitle">Request Body</h4><div class="p" id="modelarts_03_0086__en-us_topic_0130045990_p1829834125010"><a href="#modelarts_03_0086__en-us_topic_0130045990_table188019141442">Table 2</a> describes the request parameters.
<div class="tablenoborder"><a name="modelarts_03_0086__en-us_topic_0130045990_table188019141442"></a><a name="en-us_topic_0130045990_table188019141442"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0086__en-us_topic_0130045990_table188019141442" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameters</caption><thead align="left"><tr id="modelarts_03_0086__en-us_topic_0130045990_row2085141411444"><th align="left" class="cellrowborder" valign="top" width="17%" id="mcps1.3.3.2.2.2.5.1.1"><p id="modelarts_03_0086__en-us_topic_0130045990_p887914144410">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.3.2.2.2.5.1.2"><p id="modelarts_03_0086__en-us_topic_0130045990_p588131412444">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.3.2.2.2.5.1.3"><p id="modelarts_03_0086__en-us_topic_0130045990_p1890111404419">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="53%" id="mcps1.3.3.2.2.2.5.1.4"><p id="modelarts_03_0086__en-us_topic_0130045990_p0922141448">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0086__en-us_topic_0130045990_row5939144448"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p159451474415">description</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p2097181416446">No</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p7984141443">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.3.2.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p499151454414">Service description, which contains a maximum of 100 characters. If this parameter is not set, the service description is not updated.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row0878165523919"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p12878135510399">status</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p4878125516398">No</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p7878195533917">String</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.3.2.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p6878135573918">Service status. The value can be <strong id="modelarts_03_0086__en-us_topic_0130045990_b1065941718557">running</strong> or <strong id="modelarts_03_0086__en-us_topic_0130045990_b1286132119554">stopped</strong>. If this parameter is not set, the service status is not changed. <strong id="modelarts_03_0086__en-us_topic_0130045990_b1210001017106">status</strong> and <strong id="modelarts_03_0086__en-us_topic_0130045990_b4100161031014">config</strong> cannot be modified at the same time. If both parameters exist, modify only the <strong id="modelarts_03_0086__en-us_topic_0130045990_b18100110161013">status</strong> parameter.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row15100141444414"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p410191434420">config</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p610231410445">No</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1410451464419"><strong id="modelarts_03_0086__en-us_topic_0130045990_b1072918477618">config</strong> array corresponding to <strong id="modelarts_03_0086__en-us_topic_0130045990_b772919478613">infer_type</strong></p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.3.2.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1210518145446">Service configuration. If this parameter is not set, the service is not updated. The model service is modified and the <strong id="modelarts_03_0086__en-us_topic_0130045990_b77671241114614">update_time</strong> parameter is returned only for requests with <strong id="modelarts_03_0086__en-us_topic_0130045990_b0854163912487">config</strong> updated.</p>
<ul id="modelarts_03_0086__en-us_topic_0130045990_ul15702102174112"><li id="modelarts_03_0086__en-us_topic_0130045990_li157021923416">If <strong id="modelarts_03_0086__en-us_topic_0130045990_b202251951171414">infer_type</strong> is set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b19225125131414">real-time</strong>, see <a href="#modelarts_03_0086__en-us_topic_0130045990_table6841887256">Table 3</a>.</li><li id="modelarts_03_0086__en-us_topic_0130045990_li770212213416">If <strong id="modelarts_03_0086__en-us_topic_0130045990_b167511859101419">infer_type</strong> is set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b1375255961416">batch</strong>, see <a href="#modelarts_03_0086__en-us_topic_0130045990_table6420928063">Table 4</a>.</li></ul>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row061911416350"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1361964203515">schedule</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p561919413356">No</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p176199493520"><strong id="modelarts_03_0086__en-us_topic_0130045990_b4637204016210">schedule</strong> array</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.3.2.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p20619164123510">Service scheduling configuration, which can be configured only for real-time services. By default, this parameter is not used. Services run for a long time. For details, see <a href="#modelarts_03_0086__en-us_topic_0130045990_table1892915349285">Table 5</a>.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row145217386813"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p184531138282">additional_properties</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p2045353819817">No</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.2.2.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p04533384817">Map&lt;String, Object&gt;</p>
</td>
<td class="cellrowborder" valign="top" width="53%" headers="mcps1.3.3.2.2.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p154531438986">Additional service attribute, which facilitates service management</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="modelarts_03_0086__en-us_topic_0130045990_table6841887256"></a><a name="en-us_topic_0130045990_table6841887256"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0086__en-us_topic_0130045990_table6841887256" frame="border" border="1" rules="all"><caption><b>Table 3 </b><strong id="modelarts_03_0086__en-us_topic_0130045990_b1611972455111">config</strong> parameters of <strong id="modelarts_03_0086__en-us_topic_0130045990_b11120152415515">real-time</strong></caption><thead align="left"><tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row4846788252"><th align="left" class="cellrowborder" valign="top" width="19.801980198019802%" id="mcps1.3.3.2.3.2.5.1.1"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p884819812515">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="12.564356435643564%" id="mcps1.3.3.2.3.2.5.1.2"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1985013812252">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="13.85148514851485%" id="mcps1.3.3.2.3.2.5.1.3"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1852188192520">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="53.78217821782179%" id="mcps1.3.3.2.3.2.5.1.4"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p38538832514">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row1856380258"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1786010872513">model_id</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p386268152512">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1386419814252">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p9866118172511">Model ID</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row1086798112511"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p986916812517">weight</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p687111819259">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p138731787259">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p19875118162511">Traffic weight allocated to a model. This parameter is mandatory only when <strong id="modelarts_03_0086__en-us_topic_0130045990_b127313288217">infer_type</strong> is set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b10741428525">real-time</strong>. The sum of the weights must be 100.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row1687613842514"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1187828182513">specification</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p38801282251">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p08821882254">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1732816427113">Resource specifications. Select specifications based on service requirements. </p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row1577715014366"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p49518457100">custom_spec</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1595144518103">No</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p2095144591017">Object</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p795164591015">Custom specifications. Set this parameter when you use a dedicated resource pool. For details, see <a href="modelarts_03_0082.html#modelarts_03_0082__en-us_topic_0129882788_table134334512416">Table 6</a>.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row988558102512"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1588814812519">instance_count</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p68902872512">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p18926812256">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p11894788252">Number of instances for deploying a model. The value must be greater than 0.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row208952088256"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p48972820252">envs</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1889910820252">No</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p119011483251">Map&lt;String, String&gt;</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p590416818251">(Optional) Environment variable key-value pair required for running a model. By default, this parameter is left blank.</p>
<p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1933202593313">To ensure data security, do not enter sensitive information, such as plaintext passwords, in environment variables.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row184117584514"><td class="cellrowborder" valign="top" width="19.801980198019802%" headers="mcps1.3.3.2.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1984255875116">cluster_id</p>
</td>
<td class="cellrowborder" valign="top" width="12.564356435643564%" headers="mcps1.3.3.2.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p28421358135110">No</p>
</td>
<td class="cellrowborder" valign="top" width="13.85148514851485%" headers="mcps1.3.3.2.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p6842125817517">string</p>
</td>
<td class="cellrowborder" valign="top" width="53.78217821782179%" headers="mcps1.3.3.2.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p4842658185112">ID of a dedicated resource pool. By default, this parameter is left blank, indicating that no dedicated resource pool is used. </p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="modelarts_03_0086__en-us_topic_0130045990_table6420928063"></a><a name="en-us_topic_0130045990_table6420928063"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0086__en-us_topic_0130045990_table6420928063" frame="border" border="1" rules="all"><caption><b>Table 4 </b><strong id="modelarts_03_0086__en-us_topic_0130045990_b1835283316219">config</strong> parameters of <strong id="modelarts_03_0086__en-us_topic_0130045990_b1535223382117">batch</strong></caption><thead align="left"><tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row12420102810614"><th align="left" class="cellrowborder" valign="top" width="19.633663366336634%" id="mcps1.3.3.2.4.2.5.1.1"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p164282280612">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="13.257425742574256%" id="mcps1.3.3.2.4.2.5.1.2"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1442892817613">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="13.643564356435645%" id="mcps1.3.3.2.4.2.5.1.3"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p942814289610">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="53.46534653465347%" id="mcps1.3.3.2.4.2.5.1.4"><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p342819281067">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row242862813615"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1042811281364">model_id</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1343542810611">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p643515281612">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p144351289614">Model ID</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row644311283615"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1444316281614">specification</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1745022815613">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p124501281565">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1445012281764">Resource flavor. </p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row104508285618"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p645020286620">instance_count</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p104501028868">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p545910281362">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1745912811612">Number of instances for deploying a model.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row245911284618"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p174598287617">envs</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p194590281468">No</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p204591928064">Map&lt;String, String&gt;</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p14459202819615">(Optional) Environment variable key-value pair required for running a model. By default, this parameter is left blank.</p>
<p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p7751032133413">To ensure data security, do not enter sensitive information, such as plaintext passwords, in environment variables.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row106241138135111"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p362417380511">src_type</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1662410381513">No</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p186242388512">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p5624163820510">Data source type. This parameter can be set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b1046312372317">ManifestFile</strong>. By default, this parameter is left blank, indicating that only files in the <strong id="modelarts_03_0086__en-us_topic_0130045990_b79791048202319">src_path</strong> directory are read. If this parameter is set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b1626445722312">ManifestFile</strong>, <strong id="modelarts_03_0086__en-us_topic_0130045990_b12264195792313">src_path</strong> must be a specific manifest file path. You can specify multiple data paths in the manifest file. </p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row27917187920"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p27919181917">src_path</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p37921815919">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p2791818799">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p137911181899">OBS path of the input data of a batch job</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row924312220920"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p13250162218914">dest_path</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p152505229917">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p122507220919">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p647112917104">OBS path of the output data of a batch job</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row47439433566"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p4743184317564">req_uri</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p97431443195610">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p769362075712">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p12743174314568">Inference API called in a batch job, which is a REST API in the model image. Select an API URI from the model <span class="parmvalue" id="modelarts_03_0086__en-us_topic_0130045990_parmvalue196235174523"><b>config.json</b></span> file for inference. If a ModelArts built-in inference image is used, the value of this parameter is <span class="parmvalue" id="modelarts_03_0086__en-us_topic_0130045990_parmvalue206297177529"><b>/</b></span>.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row34628464568"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1246314615563">mapping_type</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p16463154665614">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p127001020155716">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1935524110385">Mapping type of the input data. The value can be <strong id="modelarts_03_0086__en-us_topic_0130045990_b119471795533">file</strong> or <strong id="modelarts_03_0086__en-us_topic_0130045990_b395313912533">csv</strong>.</p>
<ul id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_ul1226004413385"><li id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_li10900195016384">If you select <strong id="modelarts_03_0086__en-us_topic_0130045990_b1382413201533">file</strong>, each inference request corresponds to a file in the input data path. When this mode is used, <strong id="modelarts_03_0086__en-us_topic_0130045990_b15824122013534">req_uri</strong> of this model can have only one input parameter and the type of this parameter is <strong id="modelarts_03_0086__en-us_topic_0130045990_b1182482013535">file</strong>.</li><li id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_li126094413816">If you select <strong id="modelarts_03_0086__en-us_topic_0130045990_b18349114925411">csv</strong>, each inference request corresponds to a row of data in the CSV file. When this mode is used, the files in the input data path can only be in CSV format and <strong id="modelarts_03_0086__en-us_topic_0130045990_b935004911548">mapping_rule</strong> must be configured to map the index of each parameter in the inference request body to the CSV file.</li></ul>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_row52721349165615"><td class="cellrowborder" valign="top" width="19.633663366336634%" headers="mcps1.3.3.2.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p172741749115618">mapping_rule</p>
</td>
<td class="cellrowborder" valign="top" width="13.257425742574256%" headers="mcps1.3.3.2.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p127454975612">No</p>
</td>
<td class="cellrowborder" valign="top" width="13.643564356435645%" headers="mcps1.3.3.2.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p12274849145617">Map</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.2.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p10153011183915">Mapping between input parameters and CSV data. This parameter is mandatory only when <strong id="modelarts_03_0086__en-us_topic_0130045990_b15174815175619">mapping_type</strong> is set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b191741615195618">csv</strong>.</p>
<p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p1643134111314">Mapping rule: The mapping rule comes from the input parameter (<strong id="modelarts_03_0086__en-us_topic_0130045990_b1542417287569">input_params</strong>) in the model configuration file <strong id="modelarts_03_0086__en-us_topic_0130045990_b1942442855612">config.json</strong>. When <span class="parmname" id="modelarts_03_0086__en-us_topic_0130045990_parmname31691644105616"><b>type</b></span> is set to <strong id="modelarts_03_0086__en-us_topic_0130045990_b1316917444567">string</strong>, <strong id="modelarts_03_0086__en-us_topic_0130045990_b2169944145610">number</strong>, <strong id="modelarts_03_0086__en-us_topic_0130045990_b1216934413563">integer</strong>, or <strong id="modelarts_03_0086__en-us_topic_0130045990_b516912445568">boolean</strong>, you are required to configure the index parameter. For details, see .</p>
<p id="modelarts_03_0086__en-us_topic_0130045990_en-us_topic_0129882788_p2043174112315">The index must be a positive integer starting from 0. If the index value does not comply with the rule, this parameter will be ignored in the request. After the mapping rule is configured, the CSV data must be separated by commas (,).</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="tablenoborder"><a name="modelarts_03_0086__en-us_topic_0130045990_table1892915349285"></a><a name="en-us_topic_0130045990_table1892915349285"></a><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0086__en-us_topic_0130045990_table1892915349285" frame="border" border="1" rules="all"><caption><b>Table 5 </b><strong id="modelarts_03_0086__en-us_topic_0130045990_b566614125320">schedule</strong> parameters</caption><thead align="left"><tr id="modelarts_03_0086__en-us_topic_0130045990_row9929133418283"><th align="left" class="cellrowborder" valign="top" width="16.831683168316832%" id="mcps1.3.3.3.2.5.1.1"><p id="modelarts_03_0086__en-us_topic_0130045990_p7929113442813">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="14.85148514851485%" id="mcps1.3.3.3.2.5.1.2"><p id="modelarts_03_0086__en-us_topic_0130045990_p49301534192811">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="14.85148514851485%" id="mcps1.3.3.3.2.5.1.3"><p id="modelarts_03_0086__en-us_topic_0130045990_p199305340285">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="53.46534653465347%" id="mcps1.3.3.3.2.5.1.4"><p id="modelarts_03_0086__en-us_topic_0130045990_p7930173472812">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0086__en-us_topic_0130045990_row1893015341284"><td class="cellrowborder" valign="top" width="16.831683168316832%" headers="mcps1.3.3.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p15930834142811">type</p>
</td>
<td class="cellrowborder" valign="top" width="14.85148514851485%" headers="mcps1.3.3.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p19930434162810">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="14.85148514851485%" headers="mcps1.3.3.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p15930193412820">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1393083414285">Scheduling type. Only the value <strong id="modelarts_03_0086__en-us_topic_0130045990_b6616426533">stop</strong> is supported.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row179301634112811"><td class="cellrowborder" valign="top" width="16.831683168316832%" headers="mcps1.3.3.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1593053482815">time_unit</p>
</td>
<td class="cellrowborder" valign="top" width="14.85148514851485%" headers="mcps1.3.3.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p10930133402815">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="14.85148514851485%" headers="mcps1.3.3.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p129301334162818">String</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p17746741122916">Scheduling time unit. Possible values are <strong id="modelarts_03_0086__en-us_topic_0130045990_b2283123120318">DAYS</strong>, <strong id="modelarts_03_0086__en-us_topic_0130045990_b20284731636">HOURS</strong>, and <strong id="modelarts_03_0086__en-us_topic_0130045990_b102841311837">MINUTES</strong>.</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row89301634162818"><td class="cellrowborder" valign="top" width="16.831683168316832%" headers="mcps1.3.3.3.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p39301334172816">duration</p>
</td>
<td class="cellrowborder" valign="top" width="14.85148514851485%" headers="mcps1.3.3.3.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1293093442817">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="14.85148514851485%" headers="mcps1.3.3.3.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p12930734202819">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="53.46534653465347%" headers="mcps1.3.3.3.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p753864762914">Value that maps to the time unit. For example, if the task stops after two hours, set <strong id="modelarts_03_0086__en-us_topic_0130045990_b1522116351834">time_unit</strong> to <strong id="modelarts_03_0086__en-us_topic_0130045990_b82228355319">HOURS</strong> and <strong id="modelarts_03_0086__en-us_topic_0130045990_b1422243512311">duration</strong> to <strong id="modelarts_03_0086__en-us_topic_0130045990_b522313351133">2</strong>.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="modelarts_03_0086__en-us_topic_0130045990_table68541815203919" frame="border" border="1" rules="all"><caption><b>Table 6 </b><strong id="modelarts_03_0086__en-us_topic_0130045990_b204289588516">custom_spec</strong> parameters</caption><thead align="left"><tr id="modelarts_03_0086__en-us_topic_0130045990_row118542155397"><th align="left" class="cellrowborder" valign="top" width="16%" id="mcps1.3.3.4.2.5.1.1"><p id="modelarts_03_0086__en-us_topic_0130045990_p19854151515397">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.3.4.2.5.1.2"><p id="modelarts_03_0086__en-us_topic_0130045990_p168541154399">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.3.4.2.5.1.3"><p id="modelarts_03_0086__en-us_topic_0130045990_p15854515113910">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="54%" id="mcps1.3.3.4.2.5.1.4"><p id="modelarts_03_0086__en-us_topic_0130045990_p1585421523918">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="modelarts_03_0086__en-us_topic_0130045990_row9854315103918"><td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.3.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p18541515133911">cpu</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1885441553910">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1085451513915">Float</p>
</td>
<td class="cellrowborder" valign="top" width="54%" headers="mcps1.3.3.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p685411593913">Number of required CPUs</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row20854121593919"><td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.3.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p28541415163919">memory</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1985410151396">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p685411515394">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="54%" headers="mcps1.3.3.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1785431583917">Required memory capacity, in MB</p>
</td>
</tr>
<tr id="modelarts_03_0086__en-us_topic_0130045990_row9854191519393"><td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.3.4.2.5.1.1 "><p id="modelarts_03_0086__en-us_topic_0130045990_p15854215133919">gpu_p4</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.4.2.5.1.2 "><p id="modelarts_03_0086__en-us_topic_0130045990_p18854115143910">No</p>
</td>
<td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.3.4.2.5.1.3 "><p id="modelarts_03_0086__en-us_topic_0130045990_p1685401520391">Float</p>
</td>
<td class="cellrowborder" valign="top" width="54%" headers="mcps1.3.3.4.2.5.1.4 "><p id="modelarts_03_0086__en-us_topic_0130045990_p19854171520391">Number of GPUs, which can be decimals. This parameter is optional. By default, it is not used.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="modelarts_03_0086__en-us_topic_0130045990_section54078976"><h4 class="sectiontitle">Response Body</h4><p id="modelarts_03_0086__en-us_topic_0130045990_p12262245525">None</p>
</div>
<div class="section" id="modelarts_03_0086__en-us_topic_0130045990_section1810193414711"><h4 class="sectiontitle">Samples</h4><p id="modelarts_03_0086__en-us_topic_0130045990_p1626113524475">The following shows how to update a real-time service.</p>
</div>
<ul id="modelarts_03_0086__en-us_topic_0130045990_ul11661134735818"><li id="modelarts_03_0086__en-us_topic_0130045990_li8663184755814">Sample request<pre class="screen" id="modelarts_03_0086__en-us_topic_0130045990_screen1815816535552">PUT https://endpoint/v1/{project_id}/services/{service_id}
{
"description": "",
"status": "running",
"config": [{
"model_id": "xxxx",
"weight": "100",
"specification": "modelarts.vm.cpu.2u",
"instance_count": 1
}]
}</pre>
</li></ul>
<ul id="modelarts_03_0086__en-us_topic_0130045990_ul163453474715"><li id="modelarts_03_0086__en-us_topic_0130045990_li1533103454717">Sample response<pre class="screen" id="modelarts_03_0086__en-us_topic_0130045990_screen29439035618">{}</pre>
</li></ul>
<div class="section" id="modelarts_03_0086__en-us_topic_0130045990_section16948739"><h4 class="sectiontitle">Status Code</h4><p id="modelarts_03_0086__en-us_topic_0130045990_p1731954913014">For details about the status code, see <a href="modelarts_03_0094.html#modelarts_03_0094__en-us_topic_0132773864_table1450010510213">Table 1</a>.</p>
</div>
<div class="section" id="modelarts_03_0086__section27281325181210"><h4 class="sectiontitle">Error Codes</h4><p id="modelarts_03_0086__p1572811255123">See <a href="modelarts_03_0095.html">Error Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="modelarts_03_0081.html">Service Management</a></div>
</div>
</div>