First time here? Check out the Help page!

Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
4

How to run GenOpt?

asked 9 years ago

jane91's avatar

updated 9 years ago

Hello,

I tried to run GenOpt (example file) but I found a error sign on the left side of the picture...

Main Window

image description

1.My question is how can i run GenOpt and see the graph?? ( the error sign!!)

2.I just copied

Parameter{
Name = w;
Ini = 1.5; Step = 0.05;
Min = 1; Max = 2;
Type = CONTINUOUS;}
Function{
Name = h; Function = "multiply( %w%, 0.5 )";}

this one in the command( i just followed tutorial) is it okay just copy and paste in comand file?

3.And this

ObjectiveFunctionLocation{

    Name1 = E_tot; 
    Function1 = "add( %E_heat%, %E_cool% )";

     Name2 = E_heat; 
     Delimiter2 = "Eheat=";

     Name3 = E_cool;
     Delimiter3 = "Ecool=";

    Name4 = height; 
    Function4 = %h%;
    }

I also copied this one in optWinXP file?

Thanks!

Preview: (hide)

Comments

Do you actually have singleZonePuchAir.idfUSA_IL_Chiaco-OHare_TMY2.epw and RunEPlusPArallel.bat in the specified folder? also, did you check you're using the right E+ version?

Julien Marrec's avatar Julien Marrec  ( 9 years ago )

Yes! I put all files in the same folder! :( What's wrong with me?! Thanks!!!

jane91's avatar jane91  ( 9 years ago )
1

image description

jane91's avatar jane91  ( 9 years ago )

I don't think anything is wrong with you :)

Julien Marrec's avatar Julien Marrec  ( 9 years ago )

4 Answers

Sort by » oldest newest most voted
4

answered 9 years ago

updated 9 years ago

What E+ version do you have installed, and where?

It seems GenOpt is trying to run a very old version of E+, 3.1.0.

I'm assuming you are trying to run the example file in GenOpt\example\energyplus\3_1_0\GPSHookeJeeves

If you open RunEPlusParallel.bat, you'll see the path to E+ is hardcoded:

set program_path=C:\Program Files\EnergyPlusV3-1-0\

Unless you have E+ 3.1.0 installed in the above directory (which is extremely unlikely), it can't work!


Update

Considering there was a similar question asked, I've put together a tutorial on how to run GenOpt. Refer to my answer here or my Github directly

Preview: (hide)
link
2

answered 9 years ago

Alex Vlachokostas's avatar

updated 9 years ago

Besides Jullien's critical note (to update the hard coded path) you have to update the idf models of the GenOpt tutorial as well to match the E+ version that you are currently running. As of now (Aug 2015) in the GenOpt download the idf files under the latest folder named 'energyplus7_0_0' need to be updated to whatever version of E+ you are running. Update the idf files by using the IDFVersionUpdater which is located under the 'PreProcess' folder of your main E+ installation folder. In my case I updated those idf files from version 7 to 7.1 to 7.2 to 8 to 8.1 up to finally 8.2 and did Jullien's hard code correction as well and the simulation run smoothly.
P.S. there is no '.bat' file at the 'energyplus7_0_0' folder therefore you can copy the one from 'energyplus5_0_0' folder.

Preview: (hide)
link
2

answered 9 years ago

Julien is right, it seems like the problem is your E+ path. Having gone through similar errors with GenOpt, I would also add that make sure that you have your variables marked in the template idf. This should not be a problem given that you are using the tutorial files.

One other common error I used to get with GenOpt was when the number of my algebraic calculations command file were more than a certain number. It seems as if GenOpt would terminate over a certain line of code in the command line and would not be able to complete all the addition/subtraction/multiplication etc. functions that I wanted.

Preview: (hide)
link
1

answered 9 years ago

samks123's avatar

Hi All,

I am actually facing the same issues with GenOpt.

The error that I am obtaining when I try to run the first tutorial (GenOpt\example\energyplus\7_0_0\GPSHookeJeeves) is as follows:


Assigning 4 threads for simulations. Initialize. java.lang.Exception:

Exception in executing the simulation program

Simulation working directory : 'C:\Users\SambuKS\Documents\GenOpt\example\energyplus\7_0_0\GPSHookeJeeves\tmp-genopt-run-1' Command string : 'cmd /C ""C:\Program Files (x86)\EnergyPlusV7-0-0\RunEPlus.bat" "singleZonePurchAir" "USA_IL_Chicago-OHare.Intl.AP.725300_TMY3""' Exception message:

Error in executing the simulation program Exit value of the simulation program: 1 Working directory : 'C:\Users\SambuKS\Documents\GenOpt\example\energyplus\7_0_0\GPSHookeJeeves\tmp-genopt-run-1'. Current command String : 'cmd /C ""C:\Program Files (x86)\EnergyPlusV7-0-0\RunEPlus.bat" "singleZonePurchAir" "USA_IL_Chicago-OHare.Intl.AP.725300_TMY3""'. Error stream of simulation program : The system cannot find the path specified.

GenOpt terminated with error.

See logfile for further information.

Looks like it is looking for Eplus.bat Version 7.....

  • I have updated the E+ version by using the IDFVersionUpdater. From v7 to v8.3 .

  • In addition, as there is no 'RuenEplusPaarallel.bat' file at the 'energyplus7_0_0' folder I copied one from 'energyplus5_0_0' folder.

-I have also considered to change the weather file versions to the latest ones from E+ v8.3.3.

Any suggestions???

Best Regards,

Preview: (hide)
link

Comments

The error is not with GenOpt but with your command string. Try running your command string from command prompt while using C:\Users\SambuKS\Documents\GenOpt\example\energyplus\7_0_0\GPSHookeJeeves\tmp-genopt-run-1 as your current directory.

GilbertLM's avatar GilbertLM  ( 9 years ago )
1

Thanks for your reply Gilbert, unfortunately that does not works.... See below:

C:\Users\SambuKS>Documents\GenOpt\example\energyplus\7_0_0\GPSHookeJeeves\tmp-ge nopt-run-1> The syntax of the command is incorrect. C:\Users\SambuKS>cd.. C:\Users>cd..

C:>\Users\SambuKS\Documents\GenOpt\example\energyplus\7_0_0\GPSHookeJeeves\tmp- genopt-run-1 '\Users\SambuKS\Documents\GenOpt\example\energyplus\7_0_0\GPSHookeJeeves\tmp-gen opt-run-1' is not recognized as an internal or external command, operable program or batch file

samks123's avatar samks123  ( 9 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Training Workshops

Careers

Question Tools

1 follower

Stats

Asked: 9 years ago

Seen: 1,340 times

Last updated: Dec 04 '15