NICTA / SmartGridToolbox

Smart Grid Simulation Library (C++14)
http://nicta.github.io/SmartGridToolbox
24 stars 10 forks source link

For Release binary Problem: Exec format error? #40

Closed pfsun closed 8 years ago

pfsun commented 8 years ago

Hi SmartGridToolbox Team,

I just download the release version. I try to execute the pvdemo, and I get the error: bash: ./pvdemo: cannot execute binary file: Exec format error. My machine is Ubuntu 14.04 64bit.

Thanks

dexterurbane commented 8 years ago

Hi there,

To help you out, I’ll probably need to know much more information. But for now, I can say the following:

  1. We don’t do binary releases, so you’ll need to build from scratch.
  2. I’d recommend using git / github to checkout a recent version of SmartGridToolbox. I use:

git clone https://github.com/NICTA/SmartGridToolbox.git

This will get you the “master” branch of SmartGridToolbox, which is stable-ish.

I don’t think I have published a “release” for quite some time (and I should do so ASAP), so if you download the latest release rather than using git, you’ll miss out on some good improvements. Also, using git makes the process of obtaining new bugfixes and updates much easier.

  1. Building using Ubuntu 14.4 is fine. You’re best off using g++4.9 or later. Read the INSTALL file to find out which third party components need to be installed, etc. and to get some tips.

We haven’t had too many people from outside our organisation try to build SmartGridToolbox, and it is pretty much just me working on it, so it is quite possible that some of the information about building is out of date. I’m really happy to help out with any problems you might have, and would welcome any information I can get from you about what doesn’t work, etc. You can probably expect that there will be some bumps in the road before you manage to get things running.

  1. The PV demo requires gurobi.

——————————

At present, I’d say the learning curve is reasonably steep, and you need decent C++ development skills. You should think of SmartGridToolbox as being primarily a library for developing custom software rather than a standalone tool for power systems analysis.

There’s heaps more help and information I can give, but I think the best idea is if you give me a bit more detail and I’ll have a much better chance of being able to help you out.

Cheers, Dan

On 31 Jul 2016, at 11:20 PM, pfsun notifications@github.com wrote:

Hi SmartGridToolbox Team,

I just download the release version. I try to execute the pvdemo, and I get the error: bash: ./pvdemo: cannot execute binary file: Exec format error. My machine is Ubuntu 14.04 64bit.

Thanks

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/NICTA/SmartGridToolbox/issues/40, or mute the thread https://github.com/notifications/unsubscribe-auth/ABvbLtAJkDj1tjEftzNePWxKNhvKIW8sks5qbKEOgaJpZM4JZB5K.

pfsun commented 8 years ago

Hi Dan,

Thanks for the detail answer. Now I can build SmartgridToolbox successfully. However, when I compile PvDemo, there are one error. Even if I fix this error, there will be other include error.

In file included from PvDemoSolver.cc:15:0: PvDemoSolver.h:18:41: fatal error: SgtCore/PowerFlowPtPpSolver.h: No such file or directory compilation terminated. make: *\ [PvDemoSolver.o] Error 1

dexterurbane commented 8 years ago

Hi pfsun,

Sorry for the delay in getting to this. The latest release (v. 4.0.1) of SmartGridToolbox should take care of the problem. If you git pull, you'll get all the changes you need, whether you are on the master or dev branch. Alternatively, you can download from the github website.

To run the PvDemo, you'll need to obtain and successfully compile the third party package PowerTools - also available in the SmartGridToolbox/third_party directory. (I said earlier you need Gurobi; this was, in fact, incorrect). This, in turn, requires you to install Ipopt, which itself requires some fiddling to get the correct third-party dependencies installed. Hassan Hijazi, the maintainer of PowerTools, may be able to help you out, or you can ask me about it.

When you configure SmartGridToolbox, you'll also need to specify that you wish to use the optional PowerTools support, e.g. configure CXX=g++-5 --enable-power-tools

You can then run make and make install.

I'll close this issue now, but feel free to ask for more help on this.