ModelArts UMN 22.3.0 version-20240311

Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: Lai, Weijian <laiweijian4@huawei.com>
Co-committed-by: Lai, Weijian <laiweijian4@huawei.com>
This commit is contained in:
Lai, Weijian 2024-04-05 09:33:47 +00:00 committed by zuul
parent dac566cf2f
commit d12c961b08
751 changed files with 17610 additions and 9543 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,13 @@
<a name="develop-modelarts-0077"></a><a name="develop-modelarts-0077"></a>
<h1 class="topictitle1">Using Custom Images</h1>
<div id="body8662426"><p id="develop-modelarts-0077__en-us_topic_0000001309847669_p141811948914">The preset images can be used in most training scenarios. In certain scenarios, ModelArts allows you to create custom images to train models. Custom images can be used to train models in ModelArts only after they are uploaded to the Software Repository for Container (SWR).</p>
<p id="develop-modelarts-0077__en-us_topic_0000001309847669_p1295165841913">Customizing an image requires a deep understanding of containers. Use this method only if the subscribed algorithms and built-in frameworks cannot meet your requirements.</p>
<p id="develop-modelarts-0077__en-us_topic_0000001309847669_p239405164812">For details about how to use custom images supported by the new version of training, see <a href="docker-modelarts_0017.html">Training a Model Using a Custom Image</a>.</p>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="modelarts_23_0230.html">Selecting an Algorithm</a></div>
</div>
</div>

View File

@ -0,0 +1,16 @@
<a name="develop-modelarts-0079"></a><a name="develop-modelarts-0079"></a>
<h1 class="topictitle1">Specifications for Custom Images Used for Training Jobs</h1>
<div id="body0000001347889646"><p id="develop-modelarts-0079__p1037492192113">When you use a locally developed model or training script to create a custom image, ensure that the custom image complies with the specifications defined by ModelArts.</p>
<div class="section" id="develop-modelarts-0079__section26795139453"><h4 class="sectiontitle">Specifications</h4><ul id="develop-modelarts-0079__ul557515200535"><li class="SourceCode" id="develop-modelarts-0079__li18576520195314">A custom image cannot be larger than 30 GB. It is best if the custom image is no larger than 15 GB. An oversized image affects the startup of a training job.</li></ul>
<ul id="develop-modelarts-0079__ul142648262454"><li id="develop-modelarts-0079__li88571413163219">The <span class="parmname" id="develop-modelarts-0079__parmname1450252503018"><b>uid</b></span> of the default user of a custom image must be <span class="parmvalue" id="develop-modelarts-0079__parmvalue166371629153011"><b>1000</b></span>.</li><li id="develop-modelarts-0079__li17932924101616">GPU drivers cannot be installed in an custom image. When you use GPUs to run a training job, ModelArts automatically places the GPU driver in <strong id="develop-modelarts-0079__b193534166413">/usr/local/nvidia</strong> of the training environment.</li><li id="develop-modelarts-0079__li46120446715">ModelArts does not support the download of open source installation packages. Install the dependencies required by the training job in the custom image.</li></ul>
</div>
<div class="section" id="develop-modelarts-0079__section1712505175116"><h4 class="sectiontitle">Creating a Custom Image for Training Jobs</h4><ol id="develop-modelarts-0079__en-us_topic_0171858297_ol108388303371"><li id="develop-modelarts-0079__en-us_topic_0171858297_li6838173019379">Set up the Docker environment on an ECS or a local host.</li><li id="develop-modelarts-0079__en-us_topic_0171858297_li283814309373">Write a Dockerfile based on your needs and the preceding specifications to build a custom image.</li><li id="develop-modelarts-0079__li16878054121612">Upload the created custom image to SWR.</li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="docker-modelarts_0017.html">Using a Custom Image to Train Models (New-Version Training)</a></div>
</div>
</div>

View File

@ -0,0 +1,17 @@
<a name="develop-modelarts-0081"></a><a name="develop-modelarts-0081"></a>
<h1 class="topictitle1">Training Job Event</h1>
<div id="body8662426"><p id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_p17841121665213">Any key event of a training job will be recorded at the backend after the training job is displayed for you. You can check events on the training job details page.</p>
<p id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_p12484144610439">This helps you better understand the running process of a training job and locate faults more accurately when a task exception occurs. You can check the following events:</p>
<ul id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_ul686375464319"><li id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_li78631154124315">During training job preparation, you can view the preparation actions or key events of the training job.</li></ul>
<ul id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_ul19451237174313"><li id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_li10451173712432">During training job runtime, you can view key information in each phase.</li></ul>
<p id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_p973155519522">During the training process, key events can be manually or automatically refreshed.</p>
<div class="section" id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_section282962985013"><h4 class="sectiontitle">Viewing Training Job Events</h4><ol id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_ol1251152035016"><li id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_en-us_topic_0000001206009603_li79561311145814">In the left navigation pane of the ModelArts management console, choose <strong id="develop-modelarts-0081__en-us_topic_0000001231305846_b1821335077">Training Management</strong> &gt; <strong id="develop-modelarts-0081__en-us_topic_0000001231305846_b417833814714">Training Jobs</strong>. In the training job list, click a job name.</li><li id="develop-modelarts-0081__en-us_topic_0000001231154866_en-us_topic_0000001244362299_li5913146155019">In the upper right corner of the training job details page, click <strong id="develop-modelarts-0081__en-us_topic_0000001231305846_b49336161689">View Event</strong> to view the event information.</li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="modelarts_23_0288.html">Viewing Job Details</a></div>
</div>
</div>

View File

@ -0,0 +1,19 @@
<a name="devtool-modelarts_0211"></a><a name="devtool-modelarts_0211"></a>
<h1 class="topictitle1">JupyterLab Plug-ins</h1>
<div id="body32001227"><p id="devtool-modelarts_0211__en-us_topic_0000001278287421_p8060118"></p>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="devtool-modelarts_0212.html">Code Parametrization Plug-in</a></strong><br>
</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="modelarts_30_0007.html">Using JupyterLab to Develop Models</a></div>
</div>
</div>

View File

@ -0,0 +1,28 @@
<a name="devtool-modelarts_0212"></a><a name="devtool-modelarts_0212"></a>
<h1 class="topictitle1">Code Parametrization Plug-in</h1>
<div id="body32001227"><div class="section" id="devtool-modelarts_0212__en-us_topic_0000001278648233_section15178143018477"><h4 class="sectiontitle">Use Guide</h4><ul id="devtool-modelarts_0212__en-us_topic_0000001278648233_ul13081050114815"><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li887271316443">The <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b04103264206">Add Form</strong> and <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b2410162610207">Edit Form</strong> buttons are available only to the shortcut menu of code cells.<div class="fignone" id="devtool-modelarts_0212__en-us_topic_0000001278648233_fig4195103317548"><span class="figcap"><b>Figure 1 </b>Viewing a code cell</span><br><span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image03085505485" src="en-us_image_0000001846137413.png" width="NaN" height="NaN"></span></div>
</li></ul>
<ul id="devtool-modelarts_0212__en-us_topic_0000001278648233_ul1169712592471"><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li12697195918473">After opening new code, add a form before editing it.<div class="fignone" id="devtool-modelarts_0212__en-us_topic_0000001278648233_fig3931162704811"><span class="figcap"><b>Figure 2 </b>Shortcut menu of code cells</span><br><span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image2071422117273" src="en-us_image_0000001799498236.png" width="497.42" height="261.877"></span></div>
</li></ul>
</div>
<p id="devtool-modelarts_0212__en-us_topic_0000001278648233_p179015205381"></p>
<div class="section" id="devtool-modelarts_0212__en-us_topic_0000001278648233_section135951730185620"><h4 class="sectiontitle">Add Form</h4><p id="devtool-modelarts_0212__en-us_topic_0000001278648233_p20398192011577">If you click <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b10378141821019">Add Form</strong>, a code cell will be split into the code and form edit area. Click <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b117271541181116">Edit</strong> on the right of the form to change the default title.</p>
<div class="fignone" id="devtool-modelarts_0212__en-us_topic_0000001278648233_fig19247184119564"><span class="figcap"><b>Figure 3 </b>Two edit areas</span><br><span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image10505158122310" src="en-us_image_0000001846057345.png" width="523.6875" height="22.472877"></span></div>
</div>
<div class="section" id="devtool-modelarts_0212__en-us_topic_0000001278648233_section144126215588"><h4 class="sectiontitle">Edit Form</h4><p id="devtool-modelarts_0212__en-us_topic_0000001278648233_p1183253810589">If you click <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b133373384126">Edit Form</strong>, four sub-options will be displayed: <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b12308843181211">Add new form field</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b224134591217">Hide code</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b957144718120">Hide form</strong>, and <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b446574917129">Show All</strong>.</p>
</div>
<ul id="devtool-modelarts_0212__en-us_topic_0000001278648233_ul2166716588"><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li3164775818">You can set the form field type to <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b823195151416">dropdown</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b854496121414">input</strong>, and <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b343988141411">slider</strong>. See <a href="#devtool-modelarts_0212__en-us_topic_0000001278648233_fig86841216610">Figure 4</a>. Each time a field is added, the corresponding variable is added to the code and form areas. If a value in the form area is changed, the corresponding variable in the code area is also changed.<div class="note" id="devtool-modelarts_0212__en-us_topic_0000001278648233_note721273918312"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="devtool-modelarts_0212__en-us_topic_0000001278648233_p42121939539">When creating a dropdown form, click <span class="parmname" id="devtool-modelarts_0212__en-us_topic_0000001278648233_parmname421215394315"><b>ADD Item</b></span> and add at least two items. See <a href="#devtool-modelarts_0212__en-us_topic_0000001278648233_fig946213314619">Figure 5</a>.</p>
</div></div>
<div class="fignone" id="devtool-modelarts_0212__en-us_topic_0000001278648233_fig86841216610"><a name="devtool-modelarts_0212__en-us_topic_0000001278648233_fig86841216610"></a><a name="en-us_topic_0000001278648233_fig86841216610"></a><span class="figcap"><b>Figure 4 </b>Form style of dropdown, input, and slider </span><br><span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image11684821568" src="en-us_image_0000001799498252.png" height="144.3449" width="492.1"></span></div>
<div class="fignone" id="devtool-modelarts_0212__en-us_topic_0000001278648233_fig946213314619"><a name="devtool-modelarts_0212__en-us_topic_0000001278648233_fig946213314619"></a><a name="en-us_topic_0000001278648233_fig946213314619"></a><span class="figcap"><b>Figure 5 </b>Creating a dropdown form</span><br><span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image1446912682717" src="en-us_image_0000001846057329.png" width="492.1" height="281.4679"></span></div>
<div class="fignone" id="devtool-modelarts_0212__en-us_topic_0000001278648233_fig16901112315137"><span class="figcap"><b>Figure 6 </b>Deleting a form</span><br><span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image37784542245" src="en-us_image_0000001846137397.png" width="492.1" height="105.8015"></span></div>
<ul id="devtool-modelarts_0212__en-us_topic_0000001278648233_ul145271618171114"><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li19489155935814">If the form field type is set to <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b365132192810">dropdown</strong>, the supported variable types are <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b36515216289">raw</strong> and <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b565225289">string</strong>.<span><img id="devtool-modelarts_0212__en-us_topic_0000001278648233_image1666026284" src="en-us_image_0000001846058197.png"></span> </li><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li61281350165917">If the form field type is set to <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b1233732872816">input</strong>, the supported variable types are <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b833782862818">boolean</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b193371528162814">date</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b18337162813283">integer</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b15338528132812">number</strong>, <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b19338828182814">raw</strong>, and <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b19338628122811">string</strong>.</li><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li137212054101215">If the form field type is set to <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b165435381610">slider</strong>, the minimum value, maximum value, and step can be set.</li></ul>
</li><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li11110850121412">If you click <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b1435243141716">Hide code</strong>, the code area will be hidden.</li><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li6668418141513">If you click <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b13294312131713">Hide form</strong>, the form area will be hidden.</li><li id="devtool-modelarts_0212__en-us_topic_0000001278648233_li13498194113156">If you click <strong id="devtool-modelarts_0212__en-us_topic_0000001278648233_b522211591715">Show All</strong>, both the code and form areas will be displayed.</li></ul>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="devtool-modelarts_0211.html">JupyterLab Plug-ins</a></div>
</div>
</div>

View File

@ -0,0 +1,17 @@
<a name="docker-modelarts_0016"></a><a name="docker-modelarts_0016"></a>
<h1 class="topictitle1">FAQ</h1>
<div id="body0000001260359615"></div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="docker-modelarts_0018.html">How Can I Upload Images to SWR?</a></strong><br>
</li>
<li class="ulchildlink"><strong><a href="docker-modelarts_0019.html">How Do I Configure Environment Variables for an Image?</a></strong><br>
</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="en-us_topic_0000001799497932.html">Using Custom Images</a></div>
</div>
</div>

View File

@ -0,0 +1,17 @@
<a name="docker-modelarts_0017"></a><a name="docker-modelarts_0017"></a>
<h1 class="topictitle1">Using a Custom Image to Train Models (New-Version Training)</h1>
<div id="body0000001348049614"></div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="develop-modelarts-0079.html">Specifications for Custom Images Used for Training Jobs</a></strong><br>
</li>
<li class="ulchildlink"><strong><a href="docker-modelarts_0029.html">Migrating an Image to ModelArts Training</a></strong><br>
</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="en-us_topic_0000001799497932.html">Using Custom Images</a></div>
</div>
</div>

View File

@ -0,0 +1,23 @@
<a name="docker-modelarts_0018"></a><a name="docker-modelarts_0018"></a>
<h1 class="topictitle1">How Can I Upload Images to SWR?</h1>
<div id="body0000001263071618"><p id="docker-modelarts_0018__p1380521175916">This section describes how to upload images to SWR.</p>
<div class="section" id="docker-modelarts_0018__section43027110533"><h4 class="sectiontitle">Step 1 Logging In to SWR</h4><ol id="docker-modelarts_0018__ol1278616324614"><li id="docker-modelarts_0018__li4786832465">Log in to the SWR console.</li><li id="docker-modelarts_0018__li37874316461">Click <strong id="docker-modelarts_0018__b8910052193215">Create Organization</strong> in the upper right corner and enter an organization name to create an organization. <strong id="docker-modelarts_0018__b117698616421553">deep-learning</strong> is used as an example. The organization name <strong id="docker-modelarts_0018__b184964644021553">deep-learning</strong> used in subsequent commands must be replaced with the actual organization name.</li><li id="docker-modelarts_0018__li1925165915499">Click <strong id="docker-modelarts_0018__b123211914163311">Generate Login Command</strong> in the upper right corner to obtain a login command.<div class="fignone" id="docker-modelarts_0018__fig93322058205316"><span class="figcap"><b>Figure 1 </b>Login Command</span><br><span><img id="docker-modelarts_0018__image102151296372" src="en-us_image_0000001853022313.png" width="469.49" height="228.90630000000004"></span></div>
</li><li id="docker-modelarts_0018__li58381625119">Log in to the ECS environment as the <strong id="docker-modelarts_0018__b161713153352">root</strong> user and enter the login command.<div class="fignone" id="docker-modelarts_0018__fig181834163710"><span class="figcap"><b>Figure 2 </b>Login command executed on the ECS</span><br><span><img id="docker-modelarts_0018__image922091918017" src="en-us_image_0000001799498612.png" width="498.351" height="44.834300000000006"></span></div>
</li></ol>
</div>
<div class="section" id="docker-modelarts_0018__section99741223135314"><h4 class="sectiontitle">Step 2 Uploading Images to SWR</h4><div class="p" id="docker-modelarts_0018__p7381174918537">This section describes how to upload an image to SWR.<ol id="docker-modelarts_0018__ol412563218195"><li id="docker-modelarts_0018__li14647102817199">Log in to SWR and tag the image to be uploaded. Replace the organization name <strong id="docker-modelarts_0018__b147176226521553">deep-learning</strong> in subsequent commands with the actual organization name configured in step 1.<pre class="screen" id="docker-modelarts_0018__screen119921642142116">sudo docker tag tf-1.13.2:latest swr.xxx.com/deep-learning/tf-1.13.2:latest</pre>
</li><li id="docker-modelarts_0018__li354527132015">Run the following command to upload the image:<pre class="screen" id="docker-modelarts_0018__screen0536156142412">sudo docker push swr.xxx.com/deep-learning/tf-1.13.2:latest</pre>
<div class="p" id="docker-modelarts_0018__p16922149105312"><div class="fignone" id="docker-modelarts_0018__fig10880134116532"><span class="figcap"><b>Figure 3 </b>Uploading an image</span><br><span><img id="docker-modelarts_0018__image1960593013410" src="en-us_image_0000001799338848.png" width="470.022" height="220.80660000000003"></span></div>
</div>
</li><li id="docker-modelarts_0018__li31358241555">After the image is uploaded, choose <strong id="docker-modelarts_0018__b1285335421553">My Images</strong> on the left navigation pane of the SWR console to view the uploaded custom images.<p id="docker-modelarts_0018__p1164485945420"><span class="parmname" id="docker-modelarts_0018__parmname1644359175414"><b>swr.xxx.com/deep-learning/tf-1.13.2:latest</b></span> is the SWR URL of the custom image.</p>
</li></ol>
</div>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="docker-modelarts_0016.html">FAQ</a></div>
</div>
</div>

View File

@ -0,0 +1,11 @@
<a name="docker-modelarts_0019"></a><a name="docker-modelarts_0019"></a>
<h1 class="topictitle1">How Do I Configure Environment Variables for an Image?</h1>
<div id="body0000001263391410"><p id="docker-modelarts_0019__p78211789182">In a Dockerfile, use the ENV instruction to configure environment variables. For details, see <a href="https://docs.docker.com/engine/reference/builder/#env" target="_blank" rel="noopener noreferrer">Dockerfile reference</a>.</p>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="docker-modelarts_0016.html">FAQ</a></div>
</div>
</div>

View File

@ -0,0 +1,33 @@
<a name="docker-modelarts_0029"></a><a name="docker-modelarts_0029"></a>
<h1 class="topictitle1">Migrating an Image to ModelArts Training</h1>
<div id="body0000001347729722"><p id="docker-modelarts_0029__p0356201419584">To migrate an image to the new training management version, perform the following operations:</p>
<ol id="docker-modelarts_0029__ol1048413498553"><li id="docker-modelarts_0029__li632551775716">Add the default user group <strong id="docker-modelarts_0029__b87995467921547">ma-group</strong> (<strong id="docker-modelarts_0029__b13944737621547">GID</strong> = <strong id="docker-modelarts_0029__b117189825321547">100</strong>) for the image of the new-version training management. If the user group whose <strong id="docker-modelarts_0029__b86551618111012">GID</strong> is <strong id="docker-modelarts_0029__b14951320141017">100</strong> exists, skip this step.</li><li id="docker-modelarts_0029__li448464915556">Add the default user <strong id="docker-modelarts_0029__b31619761121547">ma-user</strong> (<strong id="docker-modelarts_0029__b106770309421547">UID</strong> = <strong id="docker-modelarts_0029__b200918502721547">1000</strong>) for the image of the new-version training management. If the user whose <strong id="docker-modelarts_0029__b7181835161011">UID</strong> is <strong id="docker-modelarts_0029__b3199163815103">1000</strong> exists, skip this step.</li><li id="docker-modelarts_0029__li285653105710">Modify the permission on files in the image to allow <strong id="docker-modelarts_0029__b116980724921547">ma-user</strong> whose <strong id="docker-modelarts_0029__b713681551110">UID</strong> is <strong id="docker-modelarts_0029__b885612205117">1000</strong> to read and write the files.</li></ol>
<p id="docker-modelarts_0029__p1299711565019">You can modify an image by referring to the following Dockerfile so that the image complies with specifications for custom images of the new-version training management.</p>
<pre class="screen" id="docker-modelarts_0029__screen18742191112347">FROM {<em id="docker-modelarts_0029__i7484046181713">An existing image</em>}
USER root
RUN groupadd ma-group -g 100 &amp;&amp; \
useradd -d /home/ma-user -m -u 1000 -g 100 -s /bin/bash ma-user
# [important] avoid missing training log
ENV PYTHONUNBUFFERED=1
USER ma-user
WORKDIR /home/ma-user</pre>
<p id="docker-modelarts_0029__p218745113113">In the new-version training management, custom images are executed by the user whose <strong id="docker-modelarts_0029__b61721059188">UID</strong> is <strong id="docker-modelarts_0029__b94062718185">1000</strong> by default. Before using an image in the new-version training management, check image file permissions on the server where the image was built. The process is as follows:</p>
<p id="docker-modelarts_0029__p147134521553">Run the following command to specify the user whose <strong id="docker-modelarts_0029__b1571616309185">UID</strong> is <strong id="docker-modelarts_0029__b1970063312185">1000</strong> to run the image:</p>
<pre class="screen" id="docker-modelarts_0029__screen67390521812">docker run -u 1000 -ti {<em id="docker-modelarts_0029__i78229412421547">Custom image</em>} bash</pre>
<p id="docker-modelarts_0029__p386035514473">Run the boot command (such as the following command) in the container during image runtime:</p>
<pre class="screen" id="docker-modelarts_0029__screen1321718914814">python train.py</pre>
<p id="docker-modelarts_0029__p455115154218">Check whether there are any <strong id="docker-modelarts_0029__b132273161421547">Permission denied</strong> error.</p>
<p id="docker-modelarts_0029__p1488048387">If <strong id="docker-modelarts_0029__b106219748221547">Permission denied</strong> is displayed for a file, for example, <strong id="docker-modelarts_0029__b132892701621547">train.py</strong>, run the following command to change the file that belongs to the user whose <strong id="docker-modelarts_0029__b10931172384217">UID</strong> is <strong id="docker-modelarts_0029__b442142554216">1000</strong>:</p>
<pre class="screen" id="docker-modelarts_0029__screen1617216415361">chown 1000 train.py</pre>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="docker-modelarts_0017.html">Using a Custom Image to Train Models (New-Version Training)</a></div>
</div>
</div>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 141 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

Some files were not shown because too many files have changed in this diff Show More