0 votes
asked by (120 points)

I meet some problem on installing ITensor. I install it as the instructions provided on their website, but when I test the performance by using the sample file, the sample can not work.

The following step is what I installed before

  1. Since my computer is based on win10, so I install Cygwin, and i search 'make', 'gcc', and 'lapack' on the search window and install these file which related to the above keyword.

  2. On the setting of options.mk, I select GCC on Windows cygwin and CCCOM=g++ -std=c++11 -Wa,-mbig-obj -O2 -fPIC. But I didnot find the suitable 'PLATFORM' , ' BLASLAPACKINCLUDEFLAGS' and 'BLASLAPACKLIBFLAGS' setting, but I choose the one which is mentioned ' Example using a C interface to LAPACK on GNU/LINUX systems'.

  3. After the setting of options.mk, i started to type 'make' command on cygwin, and no error happened but there are several warnings.

  4. So I think the library has been builded, then I want to test it by using the sample folder provided by ITensor. I can also get some .exe file after i typing 'make' command on cygwin, but i can not execute those .exe file. The error is 'cygstdc++.dll', 'cygwin1.dll','cygblas-0.dll' and 'cyggcc_s-seh-a.dll' are missing, and tell me I need to reinstall the program, but when I reinstall the program, I can not find the above file when i type the keywords on the search window.

Is there any setting I missed? I can just find the official install instruction on google and no other detailed type.

2 Answers

0 votes
answered by (70.1k points)

Hi, it sounds like you are doing everything correctly but that there is a problem with your compiler setup inside Cygwin.

Could you try first compiling a basic C++ program (just a main that prints out "Hello world") and running that to see if it works? By basic I mean not including any of ITensor in your program. Also try including something from the C++ standard library, such as making a std::vector to make sure that also works.

That could help clarify what is going on. From the error message it sounds like you might need to uninstall Cygwin completely and reinstall it.

Best regards,
Miles

commented by (200 points)
Do you have experience of installing itensor on cygwin? If so, would you please upload or copy your mk file here? That will help a lot.
commented by (120 points)
I can run the sample now , the solution is put the above missing  .dll files into /C/WINDOWS/system32. Those .dll files are already in /cygwin64/bin, there is no need to reinstall cygwin64 again.
commented by (200 points)
I still cannot run the sample. My error is cannot find -lblas and -llapck. Did you explicity install lapack and blas on cygwin before installing itensor? Do you place the itensor in the same directory as cygwin? I want to copy your installation steps. Would you please contact me at qzwtb@mst.edu?
commented by (70.1k points)
If it helps, I recall that on Cygwin and other Linux installations one usually needs to install an extra package with a name like "lapack-devel" in order to get the lapack headers in addition to just the lapack libraries themselves.
+1 vote
answered by (200 points)

Would you please upload your mk file or copy your mk file here so that we can read it ?

commented by (120 points)
ok, the first two part of my .mk file is :

### User Configurable Options

## To set up, follow the steps [1], [2], [3] below

#########
## [1]
##
## Set which compiler to use by defining CCCOM:
## GNU GCC compiler
#CCCOM=g++ -m64 -std=c++11 -fPIC

## Clang compiler (good to use on Mac OS)
#CCCOM=clang++ -std=c++11 -fPIC

## GCC On Windows cygwin
## Extra flags are workaround for limitations
## of this compiler with Windows binary format
CCCOM=g++ -std=c++11 -Wa,-mbig-obj -O2 -fPIC

## Intel C++ Compiler not recommended,
## As of June 2016 it does not fully support C++11

#########

#########
## [2]
##
## BLAS/LAPACK Related Options
##
## o The variable PLATFORM can be set to macos,lapack,mkl, or acml.
##   This tells ITensor which style of BLAS/Lapack library to expect,
##   and turns various lines of code on or off inside the files
##   itensor/tensor/lapack_wrap.h and lapack_wrap.cc.
##
## o BLAS_LAPACK_LIBFLAGS specifies blas or lapack related
##   flags used during the linking step. For example,
##   flags of the type:
##   -L/path/to/lapack/lib -llapack -lblas
##   though the names of the static libraries (the files referred
##   to by the -l flags) can be highly variable - see examples below.
##
## o BLAS_LAPACK_INCLUDEFLAGS are blas or lapack related flags
##   needed during compilation. It may include flags such as
##   -I/path/to/lapack/include
##   where "include" is a folder containing .h header files.
##

##
## Mac OSX system
##

#PLATFORM=macos
#BLAS_LAPACK_LIBFLAGS=-framework Accelerate

##
## Example using a C interface to LAPACK on GNU/LINUX systems
## (Path to lib/ folder may differ on your system)
##

PLATFORM=lapack
BLAS_LAPACK_LIBFLAGS=-lpthread -L/usr/lib -lblas -llapack

##
## Example using the Intel MKL library
## (Path to lib/intel64/ and include/ folders may differ on your system)
##

#PLATFORM=mkl
## MKL example - you may need to change the names of the folders below
#BLAS_LAPACK_LIBFLAGS=-L/opt/intel/mkl/lib/intel64 -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_rt -lmkl_core -liomp5 -lpthread
#BLAS_LAPACK_INCLUDEFLAGS=-I/opt/intel/mkl/include

##
## Example using the OpenBLAS library (http://www.openblas.net/)
## (Path to lib/ and include/ folders may differ on your system)
##

#PLATFORM=openblas
#BLAS_LAPACK_LIBFLAGS=-lpthread -L/usr/local/opt/openblas/lib -lopenblas
#BLAS_LAPACK_INCLUDEFLAGS=-I/usr/local/opt/openblas/include -fpermissive -DHAVE_LAPACK_CONFIG_H -DLAPACK_COMPLEX_STRUCTURE

##
## Example using the AMD ACML library
## (Path to lib/ folder may differ on your system)
##

#PLATFORM=acml
#BLAS_LAPACK_LIBFLAGS=-L/opt/acml5.1.0/gfortran64/lib -lacml -lgfortran -lpthread
Welcome to ITensor Support Q&A, where you can ask questions and receive answers from other members of the community.

Formatting Tips:
  • To format code, indent by four spaces
  • To format inline LaTeX, surround it by @@ on both sides
  • To format LaTeX on its own line, surround it by $$ above and below
  • For LaTeX, it may be necessary to backslash-escape underscore characters to obtain proper formatting. So for example writing \sum\_i to represent a sum over i.
If you cannot register due to firewall issues (e.g. you cannot see the capcha box) please email Miles Stoudenmire to ask for an account.

To report ITensor bugs, please use the issue tracker.

Categories

...