Full example with LML

In this section a full example of a LML-file is shown. Nearly all components are included in this example. Below the LML-code you can see a picture showing a possible graphical output for this LML-file.

<?xml version="1.0" encoding="UTF-8"?>
<lml:lgui xmlns:lml="http://eclipse.org/ptp/lml" 
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://eclipse.org/ptp/lml lgui.xsd "
      version="1.3">
    
<objects>
    <object id="s1" type="system" color="#EEE" name="blue gene P" />
    <object id="j1" type="job" color="#F00" name="bigjob" />
    <object id="n1" type="node" color="#0F0" name="anode" />
    <object id="j2" type="job" color="#0F0" name="smalljob" />
    <object id="empty" type="job" name="empty jobs" />
    <object id="q1" type="queue" name="small jobs queue"/>
</objects>

<relations>
    <!-- all-to-all-relation -->
    <rel id="Relation1" name="allJobs">
        <el refid="j1"/>
        <el refid="j2"/>
        <el refid="empty"/>
    </rel>
    <!-- one-to-all-relation -->
    <rel id="Relation2" name="QueueGroup" keyid="q1">
        <el refid="j1"/>
        <el refid="j2"/>
    </rel>
</relations>

<information>
    <info oid="s1" type="short" description="Additional information for system">
        <data key="jobcount" value="40" />
        <data key="nodes" value="12" />
        <data key="mhz" value="800" />
    </info>
    <info oid="j2" type="short" description="Information for one Job">
        <data key="user" value="carsten" />
        <data key="cpus" value="1000" />
        <data key="language" value="java" />
    </info>
    <!-- long version for object s1 -->
    <info oid="s1" type="long" description="Information for system long version">
        <data key="jobcount" value="40" />
        <data key="nodes" value="12" />
        <data key="mhz" value="800" />
        <data key="systemname" value="jugene"/>
        <data key="type" value="batch"/>
        <data key="costs" value="1 Million"/>
    </info>
</information>

<table title="job-list" id="2">
    <!-- column definitions -->
    <column id="1" name="jobname" sort="alpha" />
    <column id="2" name="totaltasks" sort="numeric" />
    <column id="3" name="date" sort="date" />
    <!-- table content -->
    <row oid="j1">
        <cell cid="1" value="job1" />
        <cell cid="2" value="1024" />
        <cell cid="3" value="2010-06-14" />
    </row>
    
    <row oid="j2">
        <cell value="job2" />
        <cell value="512" />
        <cell value="2010-06-14" />
    </row>
    
</table>

<usagebar id="3" cpucount="3048" title="Job-Usage" cpupernode="4">
    <job oid="j1" cpucount="128"/>
    <job oid="j2" cpucount="1920" cpupernode="2"/>
    <!--if cpupernode changes within one job, jobpart-elements have to be inserted-->
    <job oid="empty" cpucount="1000">
        <jobpart cpucount="500"/>
        <jobpart cpucount="500" cpupernode="8"/>
    </job>
</usagebar>

<usagebarlayout id="ubl1" gid="3" scale="cpus" interval="512"/>

<!-- Info-boxes for various information types -->
<infobox id="4" title="General Info" type="short"/>
<infobox id="5" title="More Info" type="long"/>
<!-- textboxes -->
<!-- static text -->
<text id="6" title="Message of today">
    <text>today everything is fine</text>          
</text>
<!-- data given by key-value-pairs -->
<text id="7" title="System-Info">
    <info>
        <data key="cpu" value="1024" />
        <data key="os" value="linux" />
        <data key="name" value="jump" />
    </info>
</text>

<nodedisplay title="JUGENE" id="8">
    <!-- Description of empty system's structure -->
    <scheme>
        <el1 tagname="rack" min="1" max="72" mask="R%02d">
            <el2 tagname="nodecard" min="1" max="32" mask="-%02d">
                <el3 tagname="chip" min="1" max="32" mask="%02d">
                    <el4 tagname="cpu" min="1" max="4" mask="-%01d"/>
                </el3>
            </el2>
        </el1>
    </scheme>
    <!-- Connection of physical elements to current jobs-->
    <data>
        <el1 min="1" max="36" oid="j1" status="running">
            <el2 min="1" oid="j2"/>
            <el2 min="9" oid="j2"/>
            <el2 min="17" oid="j2"/>
            <el2 min="25" oid="j2"/>
        </el1>
        
        <el1 min="37" max="72" oid="empty" status="idle" description="racks broken"/>
    </data>
</nodedisplay>

<nodedisplay title="logical jugene" id="9" refto="8">
    <!-- new structure for the same parallel computer -->
    <scheme>
        <el1 tagname="X" min="1" max="16">
            <el2 tagname="Y" min="1" max="16" >
                <el3 tagname="Z" min="1" max="9"/>
            </el2>
        </el1>
    </scheme>
    <!-- referencing physical elements through refid -->
    <data>
        <el1 min="1">
            <el2 min="1">
                <el3 min="1" refid="R10-01"/>
                <el3 min="2" refid="R20-01"/>
                <el3 min="3" refid="R30-02"/>
                <el3 min="4" refid="R40-02"/>
                <el3 min="5" refid="R50-01"/>
                <el3 min="6" refid="R60-01"/>
            </el2>
        </el1>
    </data>
</nodedisplay>

<chart id="10" title="load in percent">
    <!-- description of axes -->
    <axes>
        <!-- X-axis -->
        <x type="linear" unit="hours" label="daytime" min="0" max="24" ticcount="24">
            <ticlabels>
                <label pos="8" text="start"/>
                <label pos="12" text="break"/>
                <label pos="18" text="end"/>
            </ticlabels>
        </x>
        <!-- Y-axis -->
        <y type="linear" unit="Percent" label="load" shortlabel="load" min="0" max="100"/>
    </axes>        
    <!-- shown data -->
    <data name="cpu load" description="system load in percent over cpu-count">
        <p x="0" y="1"/>
        <p x="3" y="10"/>
        <p x="6" y="20"/>
        <p x="9" y="50"/>
        <p x="12" y="90"/>
        <p x="15" y="50"/>
        <p x="18" y="20"/>
        <p x="21" y="0"/>
    </data>    
</chart>

<!-- define a layout for a nodedisplay -->
<nodedisplaylayout id="1" gid="8">

    <el0 rows="0" cols="8" vgap="4" hgap="0" fontsize="10" border="0"
        fontfamily="Monospaced" showtitle="false" 
        mouseborder="0" maxlevel="2" transparent="false" background="#AAA">
            <!-- no inheritance of attribute values here-->
        <el1 min="1" max="72" cols="8" hgap="0" showtitle="true">

            <el2 min="1" max="32" cols="8" vgap="0" hgap="0" >
            </el2>
            
        </el1>
    </el0>
</nodedisplaylayout>

<!-- define a layout for component-positioning -->
<splitlayout id="split1">
        <left gid="8"/>
        <right divpos="0.2">
            <top gid="3"/>
            <bottom divpos="0.5">
                <top divpos="0.5">
                    <top gid="2"/>
                    <bottom gid="10"/>
                </top>
                <bottom divpos="0.5">
                    <top divpos="0.5">
                        <left gid="4"/>
                        <right gid="5"/>
                    </top>
                    <bottom divpos="0.5">
                        <left gid="6"/>
                        <right gid="7"/>
                    </bottom>
                </bottom>
            </bottom>
        </right>
</splitlayout>
    
</lml:lgui>
Full LML-example

possible output for lml-example
possible output for this LML-source


Home | last change 20.08.2013 | copyright see Copyright and Disclaimer | contact: c.karbach@fz-juelich.de