Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Google Earth

leilagh
2012-11-09
2015-03-17
  • leilagh
    leilagh
    2012-11-09

    We have a problem with the outputs for Google earth; I would like to know that if  it is  possible for us  to add our output data to google earth data and make them compatible?

     
  • Jason Fuller
    Jason Fuller
    2012-11-10

    Leilagh,

    It's always, of course, possible - of course, time and effort is the real key =)

    We originally had visions of supporting KML, however, that effort was halted after some initial tests - again, time and effort did not meet with the needs of the client.  You are welcome to look at how far we were able to get in powerflow.  Good examples can be found in node and link, under the kmldump function.  This would basically allow you to set a flag to activate KML dump, then dump to the right format in your specified file.  This was a very simple implementation, and as far as I know, still works…although its been 4 years since we've played with it.

     
  • leilagh
    leilagh
    2012-11-12

    Thank you for reply, Could you pleas give the link of the worked example?

     
  • I am not aware of any examples in the source tree that can produce KML output.  The GLM file must include latitude and longitude data in the node objects.  When present, that should trigger output of KML data when the -kml option is used on the command line:

    gridlabd myfile.glm --kml
    
     
  • leilagh
    leilagh
    2012-11-12

    I typed in command window:
    -debug -kml $File -o gridlabd -dumpall

    and for example my code is:

    module powerflow;
    object node{
             bustype SWING;
             phases ABCN;
    voltage_A +7199.558+0.000j;
    voltage_B -3599.779-6235.000j;
    voltage_C -3599.779+6235.000j;  
             nominal_voltage 7200;     
             latitude  49N12'34.0";
             longitude  121W15'48.3";
           
    }

    I doesn't work well. What should I do?

    object node:1{
             bustype SWING;
             phases ABCN;
    voltage_A +7199.558+0.000j;
    voltage_B -3599.779-6235.000j;
    voltage_C -3599.779+6235.000j;  
             nominal_voltage 7200;
             //latitude  49N12;//'34.0";
             //longitude  121W;//15'48.3";
           
    }

     
  • leilagh
    leilagh
    2012-11-12

    2012-11-12 11:56:36 PST
    I typed in command window: -debug -kml $File -o gridlabd -dumpall and for example my code is: module powerflow; object node{ bustype SWING; phases ABCN; voltage_A +7199.558+0.000j; voltage_B -3599.779-6235.000j; voltage_C -3599.779+6235.000j; nominal_voltage 7200; latitude 49N12'34.0"; longitude 121W15'48.3"; } It doesn't work well. What should I do?

     
  • leilagh
    leilagh
    2012-11-13

    Thank you for the answer.Again It doesn't work; I get this:
    'Tool completed with exit code -1073741790'

     
  • leilagh
    leilagh
    2012-11-14

    Thank you for the answer.Again It doesn't work; I get this:
    'Tool completed with exit code -1073741790'

     
  • I'm unable to explain why you get that error.  Such an error is usually indicative of a serious internal memory problem that it can't even print an error about. 

    Let's go back to basics.  Please provide me with details about the host system and GridLAB-D version or build you are using.  For linux machines, 'uname -a' will provide the necessary info about the host system and 'gridlabd -version' will provide the necessary info about gridlabd.  Once I have that, I can follow-up with some more specific questions that hopefully will lead us to a problem we can solve.

     
  • leilagh
    leilagh
    2012-11-15

    Mine is:  gridlabd-2.2.0-win32
    When i copy in the command window :
    "-debug -warn -verbose $File -o gridlabd -dumpall ", there is no problem(Normal).
    But when I add the longitude and latitude properties to the node and copy in the command window:  
    "-debug -kml $File -o gridlabd -dumpall ",  It does not work.

     
  • Are you running on Windows XP or Windows 7?

     
  • Please send me the GLM file also.

     
  • leilagh
    leilagh
    2012-12-05

    I am running Windows 7,

    I started it with the simplest possible statements:

    module powerflow{
            solver_method FBS;
            default_maximum_voltage_error 1e-9;
    };

    object node{
             name node1;
             bustype SWING;
             phases ABCN;
    voltage_A +7199.558+0.000j;
    voltage_B -3599.779-6235.000j;
    voltage_C -3599.779+6235.000j;  
             nominal_voltage 7200;     
             latitude  12N34.00056;
             longitude 12W34.00056;        
    }

    Thank you for attention

     
  • I put your example into a file called test.glm and run this on Grizzly (V2.3):

    host% gridlabd test.glm --kml
    WARNING [INIT] : /usr/lib/gridlabd/tzinfo.txt(37): timezone spec 'WILDABBR0WILDABBR' not found in 'tzinfo.txt', will include no DST information
    WARNING [INIT] : gridlabd.conf(32): variable 'USERNAME' not found
    

    You can ignore the warnings.  The output is

    host% more gridlabd.kml
    <?xml version="1.0" encoding="UTF-8"?>
    <kml xmlns="http://earth.google.com/kml/2.2">
      <Document>
        <name>test.glm</name>
        <description>GridLAB-D results for INIT</description>
    <Style id="overhead_line">
     <LineStyle>
      <color>7f00ffff</color>
      <width>4</width>
     </LineStyle>
     <PolyStyle>
      <color>7f00ff00</color>
     </PolyStyle>
    </Style>
    <Style id="underground_line">
     <LineStyle>
      <color>3f00ffff</color>
      <width>4</width>
     </LineStyle>
     <PolyStyle>
      <color>3f00ff00</color>
     </PolyStyle>
    </Style>
      <Folder><name>Class node</name>
        <description>Module powerflow (V2.00)</description>
    <Placemark>
    <name>node1</name>
    <description>
    <![CDATA[
    <TABLE>
    <TR><TD WIDTH="25">node&nbsp;0<HR></TD><TH WIDTH="25" ALIGN=CENTER>Phase A<HR></TH><TH WIDTH="25" ALIGN=CENTER>Phase B<HR></TH><TH WIDTH="25" ALIGN=CENTER>Phase C<HR></TH></TR>
    <TR><TH ALIGN=LEFT>Voltage</TH><TD ALIGN=RIGHT STYLE="font-family:courier;">748.200&nbsp;kV&nbsp;&nbsp;<BR>0.000&nbsp;deg&nbsp;</TD><TD ALIGN=RIGHT STYLE="font-family:courier;">748.200&nbsp;kV&nbsp;&nbsp;<BR>239.999&nbsp;deg&nbsp;</TD><TD ALIGN=RIGHT STYLE="font-family:courier;">748.200&nbsp;kV&nbsp;&nbsp;<BR>120.000&nbsp;deg&nbsp;</TD></TR>
    </TABLE>
    ]]>
    </description>
    <Point>
    <coordinates>-12.566667,12.566667</coordinates>
    </Point>
    </Placemark>
      </Folder>
      </Document>
    </kml>
    

    When I bring this up in Google Earth I get 'node1' just north of the border between Senegal and Guinea.