• 308 views | 6 messages Discussion: LEAP
    Topic: Import from excel - time slice shape into yearly shape for Energy load shape (% of annual load)Subscribe | Previous | Next
  • Nathan Lee 10/15/2020

    I am unable to import a time slice shape from excel into LEAP. Could you describe step by step how this is done?

    My computer/company does not allow me to download the "time slices demo" I see referred to elsewhere to LEAP, can you share this or is it accessible on your site? I would like an example that I can follow.

    I have attached the sheet that I am trying to import. I have named a range of 145 values which LEAP states that I need "Values_Import". It says there is an error every time about converting a null type value to a integer, and I have to restart LEAP.

    Thanks!

    Nate


    Attachments:  example load curve.xlsx [8]
  • Charlie Heaps 10/16/2020
      Best Response

    Hi Nathan,

    Here it is. Bear in mind: this particular demo is very slow when running with the free GLPK or CBC solvers. Only really works well with CPLEX or similar solver.


    https://www.dropbox.com/s/dtq6hwnex64n5qk/Time%20Slice%20Demo.leap?dl=0


    Charlie


  • Nathan Lee 10/20/2020
      Best Response

    Thanks, Charlie,

    I did not see a spreadsheet with this example that has time slices for importing data. I hoped to find an example of how to import the time-sliced data for the "Yearly Shapes"

    Could you tell me if the example spreadsheet I provided in my previous message (above) is correctly formatted for "Import from Time-Sliced Shape" excel in the "Yearly Shape" window? There is a named range there that I keep trying to import; however, whenever I select the named range in this spreadsheet to import into LEAP, I get a message that "An error occurred in Leap, EVariantTypeCastError - Could not convert variant of type (Null) into type (Integer)". Is this a common mistake?

    Essentially, I am trying to replace some energy load shapes (in yearly shapes window) as a LEAP model I am working with gives the error "Bad load shape (0%) in Transformation Module" whenever I try to run results. I am unable to find where this load profile is and hoped to replace the load shapes to see what is causing this. Are Time-Sliced Shapes for Energy Load Shapes (% of annual load) not allowed to equal zero (0) for any period?

    Thank you!

    Nate

  • Gregers Larsen 10/23/2020
      Best Response

    Hello Nathan!

    I have taught a similar problem (with the same dataset). I made a video on how to do exactly that, could be useful. The general course is not yet public.

    Here is around where I start talking about how to import yearly shapes from Excel: https://youtu.be/bTiNCMw9UW0?t=332

    Also, setting up the Optimisation model: https://youtu.be/udJRRDqZIzI (Lesson in Optimisation in LEAP)

    Also, to add to Charlie. On my laptop (i7 pretty okay powerful), the calculation took:
    • GLTK: 7 minutes per scenario
    • CBC: 4 minutes per scenario
    Good luck!


    Gregers

  • Charlie Heaps 10/23/2020
      Best Response

    Hi Nathan - sorry for slow reply. I am looking at this now. Could you send me the LEAP data set into which you are trying to import the load shape? It seems to have 12m x 12 2 hr time slices (144 slices).

    Please send as a .leap file via a dropbox link or similar. Email attachments may be too large.

    Thanks!

    Charlie

  • Nathan Lee 10/30/2020
      Best Response

    Hi Gregers,

    Thanks for sharing this! I really appreciated the resource. However, I believe that I am following these directions exactly in my version of LEAP, but still receive an error.

    I have a time slide setup for slices with 145 values. In the spreadsheet that I shared in a message above, I have 145 values in a named range. Then in LEAP I open general\yearly shapes, add a new shape and then use import\import from time-sliced shape. I can see and select my named range. After accepting to import this in LEAP, I always get the error message that I attached below.

    It seems that I have some sort of issue that I am not catching. Thanks!

    Nate


    Attachments:  ErrorMessage_HondurasLeapModelV29.pdf [4]