Page 1 of 1

installation issue?

Posted: Tue Nov 18, 2014 2:24 am
by shanekav
Hi,
Have gone through installation instructions a couple of times. I have noted thread below regarding newer version of MinGW, which I have used. I have also created a new user account with no spaces in the name. When I run a 2level impute I get the following error message:

CompileError: error: Command "g++ -O2 -Wall -DNPY_MINGW_USE_CUSTOM_MSVCR -D__MSVCRT_VERSION__=0x0900 -IC:\StatJR\src\lib\EStat\templates -IC:\StatJR\src\apps\tree\include -IC:\StatJR\src\apps\tree\include\scxx -IC:\StatJR\src\apps\tree\tree.exe\numpy\core\include -IC:\StatJR\src\apps\tree\include -IC:\StatJR\src\apps\tree\PC -c c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc5124c0286534333063e7551f46.cpp -o c:\users\shanev~1\appdata\local\temp\scipy-ShaneVersion-zeon6p\python27_intermediate\compiler_6d1da47feb68aa1f945eb2a5466ab741\Release\users\shanev~1\appdata\local\temp\shaneversion\python27_compiled\sc_e8c05bc5124c0286534333063e7551f46.o -w -O3 -std=c++11" failed with exit status 1

Could you help please?

many thanks in advance

Shane

Re: installation issue?

Posted: Tue Nov 18, 2014 2:47 pm
by richardparker
Hi - sorry you're having problems. To help resolve them it would be great if you could please send us a bit more info (the link from the browser window doesn't always include all the info we need): in the command window, which is also open when Stat-JR is running, there will be more output detailing the error (the section of text you sent will be at the bottom of it); if you were able to send us a screenshot of that, that would be very helpful, thanks.

Re: installation issue?

Posted: Tue Nov 18, 2014 10:46 pm
by shanekav
Hi Richard,
I couldn't get the screenshot to get all the text, so have cut and pasted below:


24c0286534333063e7551f49.cpp:1192:22: error: expected initializer before '_STATE
'
long* idmapdata_@_STATE = (long*) idmapdata_@_STATE_array->data;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1193:5: error: 'py_RACEGR2_Recode_4' was not declar
ed in this scope
py_RACEGR2_Recode_4 = get_variable("RACEGR2_Recode_4",raw_locals,raw_global
s);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1204:5: error: 'py_RACEGR2_Recode_5' was not declar
ed in this scope
py_RACEGR2_Recode_5 = get_variable("RACEGR2_Recode_5",raw_locals,raw_global
s);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1215:5: error: 'py_AGE' was not declared in this sc
ope
py_AGE = get_variable("AGE",raw_locals,raw_globals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1226:5: error: 'py_MARITAL_Recode_2' was not declar
ed in this scope
py_MARITAL_Recode_2 = get_variable("MARITAL_Recode_2",raw_locals,raw_global
s);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1237:5: error: 'py_' was not declared in this scope

py_@_STATE = get_variable("@_STATE",raw_locals,raw_globals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1237:9: error: expected ';' before '_STATE'
py_@_STATE = get_variable("@_STATE",raw_locals,raw_globals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1238:57: error: expected ')' before '_STATE'
PyArrayObject* @_STATE_array = convert_to_numpy(py_@_STATE,"@_STATE");
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:575:43: note: in definition of macro 'convert_to_nu
mpy'
x__numpy_handler.convert_to_numpy(py_obj,name)
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1244:17: error: expected initializer before '_STATE
'
npy_intp* N@_STATE = @_STATE_array->dimensions;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1245:17: error: expected initializer before '_STATE
'
npy_intp* S@_STATE = @_STATE_array->strides;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1246:11: error: expected initializer before '_STATE
'
int D@_STATE = @_STATE_array->nd;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1248:5: error: 'py_RACEGR2_Recode_2' was not declar
ed in this scope
py_RACEGR2_Recode_2 = get_variable("RACEGR2_Recode_2",raw_locals,raw_global
s);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1259:5: error: 'py_RACEGR2_Recode_3' was not declar
ed in this scope
py_RACEGR2_Recode_3 = get_variable("RACEGR2_Recode_3",raw_locals,raw_global
s);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1270:5: error: 'py_negZelecOff' was not declared in
this scope
py_negZelecOff = get_variable("negZelecOff",raw_locals,raw_globals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1281:5: error: 'py_idmapsizes_' was not declared in
this scope
py_idmapsizes_@_STATE = get_variable("idmapsizes_@_STATE",raw_locals,raw_gl
obals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1281:20: error: expected ';' before '_STATE'
py_idmapsizes_@_STATE = get_variable("idmapsizes_@_STATE",raw_locals,raw_gl
obals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1282:32: error: expected initializer before '_STATE
_array'
PyArrayObject* idmapsizes_@_STATE_array = convert_to_numpy(py_idmapsizes_@_
STATE,"idmapsizes_@_STATE");
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1283:33: error: 'idmapsizes_' was not declared in t
his scope
conversion_numpy_check_type(idmapsizes_@_STATE_array,PyArray_LONG,"idmapsiz
es_@_STATE");
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1288:28: error: expected initializer before '_STATE
'
npy_intp* Nidmapsizes_@_STATE = idmapsizes_@_STATE_array->dimensions;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1289:28: error: expected initializer before '_STATE
'
npy_intp* Sidmapsizes_@_STATE = idmapsizes_@_STATE_array->strides;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1290:22: error: expected initializer before '_STATE
'
int Didmapsizes_@_STATE = idmapsizes_@_STATE_array->nd;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1291:23: error: expected initializer before '_STATE
'
long* idmapsizes_@_STATE = (long*) idmapsizes_@_STATE_array->data;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1292:5: error: 'py_Zgini2004' was not declared in t
his scope
py_Zgini2004 = get_variable("Zgini2004",raw_locals,raw_globals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1303:5: error: 'py_EMPLOY_recode_2' was not declare
d in this scope
py_EMPLOY_recode_2 = get_variable("EMPLOY_recode_2",raw_locals,raw_globals)
;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1314:5: error: 'py_EDUCAG_Recode_4' was not declare
d in this scope
py_EDUCAG_Recode_4 = get_variable("EDUCAG_Recode_4",raw_locals,raw_globals)
;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1325:5: error: 'py_iiinc' was not declared in this
scope
py_iiinc = get_variable("iiinc",raw_locals,raw_globals);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1336:5: error: 'py_EDUCAG_Recode_2' was not declare
d in this scope
py_EDUCAG_Recode_2 = get_variable("EDUCAG_Recode_2",raw_locals,raw_globals)
;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1347:5: error: 'py_EDUCAG_Recode_3' was not declare
d in this scope
py_EDUCAG_Recode_3 = get_variable("EDUCAG_Recode_3",raw_locals,raw_globals)
;
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1382:34: error: expected initializer before '_STATE
'
std::vector<arrayref> idmap_@_STATE(50);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1383:36: error: 'idmap_' was not declared in this s
cope
for (int i = 0, start = 0; i < idmap_@_STATE.size(); i++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1383:43: error: expected ';' before '_STATE'
for (int i = 0, start = 0; i < idmap_@_STATE.size(); i++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1383:50: error: request for member 'size' in '_STAT
E', which is of non-class type 'long int*'
for (int i = 0, start = 0; i < idmap_@_STATE.size(); i++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1383:56: error: expected ')' before ';' token
for (int i = 0, start = 0; i < idmap_@_STATE.size(); i++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1383:58: error: 'i' was not declared in this scope
for (int i = 0, start = 0; i < idmap_@_STATE.size(); i++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1383:61: error: expected ';' before ')' token
for (int i = 0, start = 0; i < idmap_@_STATE.size(); i++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1594:63: error: 'idmap_' was not declared in this s
cope
du1(j1,j2) = mat_d_e1(j1, j2)*idmap_@_STATE[j].
size() + mat_d_u(0 + j1, 0 + j2);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1594:70: error: expected ';' before '_STATE'
du1(j1,j2) = mat_d_e1(j1, j2)*idmap_@_STATE[j].
size() + mat_d_u(0 + j1, 0 + j2);
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1600:51: error: 'idmap_' was not declared in this s
cope
for (int id_k = 0; id_k < idmap_@_STATE[j].size(); id_k
++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1600:58: error: expected ';' before '_STATE'
for (int id_k = 0; id_k < idmap_@_STATE[j].size(); id_k
++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1600:68: error: request for member 'size' in '*(_ST
ATE + ((sizetype)(((unsigned int)j) * 4u)))', which is of non-class type 'long i
nt'
for (int id_k = 0; id_k < idmap_@_STATE[j].size(); id_k
++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1600:74: error: expected ')' before ';' token
for (int id_k = 0; id_k < idmap_@_STATE[j].size(); id_k
++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1600:76: error: 'id_k' was not declared in this sco
pe
for (int id_k = 0; id_k < idmap_@_STATE[j].size(); id_k
++) {
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:1600:82: error: expected ';' before ')' token
for (int id_k = 0; id_k < idmap_@_STATE[j].size(); id_k
++) {

^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '}' at end of input
}
^
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '}' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '}' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '}' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '}' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected 'catch' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '(' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected type-specifier at end of in
put
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected ')' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '{' at end of input
c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc_e8c05bc51
24c0286534333063e7551f49.cpp:2074:1: error: expected '}' at end of input
127.0.0.1:49206 - - [19/Nov/2014 09:26:07] "HTTP/1.1 POST /get_resource/" - 200
OK
127.0.0.1:49206 - - [19/Nov/2014 09:26:08] "HTTP/1.1 POST /get_resource/" - 200
OK
DEBUG:root:Unexpected error:<class 'distutils.errors.CompileError'>
DEBUG:root:Traceback (most recent call last):
File "webtest.py", line 433, in go
File "C:\StatJR\packages\Python_script.py", line 71, in run
self.eng.run('script.py')
File "Q:\edcmjc\repo\StatJR\estat\trunk\src\lib\EStat\engines\Engine.py", line
44, in decorated
File "Q:\edcmjc\repo\StatJR\estat\trunk\src\lib\EStat\engines\Python.py", line
16, in run
File "<string>", line 189, in <module>
File "Q:\edcmjc\repo\StatJR\estat\trunk\src\apps\cmdtest\cmdtest.py", line 128
, in RunStatJR
File "C:\StatJR\packages\CustomC.py", line 891, in run
self.runcode(str(self.eng.outputs['modelcode.cpp'].content), self.vars[chain
num], self.data)
File "C:\StatJR\packages\CustomC.py", line 564, in runcode
extra_compile_args = ['-w', '-O3', '-std=c++11'])
File "c:\Python27\lib\site-packages\scipy\weave\inline_tools.py", line 366, in
inline
File "c:\Python27\lib\site-packages\scipy\weave\inline_tools.py", line 496, in
compile_function
File "c:\Python27\lib\site-packages\scipy\weave\ext_tools.py", line 373, in co
mpile
File "c:\Python27\lib\site-packages\scipy\weave\build_tools.py", line 279, in
build_extension
File "c:\Python27\lib\site-packages\numpy\distutils\core.py", line 169, in set
up
File "c:\Python27\lib\distutils\core.py", line 166, in setup
CompileError: error: Command "g++ -O2 -Wall -DNPY_MINGW_USE_CUSTOM_MSVCR -D__MSV
CRT_VERSION__=0x0900 -IC:\StatJR\src\lib\EStat\templates -IC:\StatJR\src\apps\tr
ee\include -IC:\StatJR\src\apps\tree\include\scxx -IC:\StatJR\src\apps\tree\tree
.exe\numpy\core\include -IC:\StatJR\src\apps\tree\include -IC:\StatJR\src\apps\t
ree\PC -c c:\users\shanev~1\appdata\local\temp\ShaneVersion\python27_compiled\sc
_e8c05bc5124c0286534333063e7551f49.cpp -o c:\users\shanev~1\appdata\local\temp\s
cipy-ShaneVersion-zeon6p\python27_intermediate\compiler_6d1da47feb68aa1f945eb2a5
466ab741\Release\users\shanev~1\appdata\local\temp\shaneversion\python27_compile
d\sc_e8c05bc5124c0286534333063e7551f49.o -w -O3 -std=c++11" failed with exit sta
tus 1

Re: installation issue?

Posted: Wed Nov 19, 2014 11:21 am
by richardparker
Hi - thanks for sending that info - it looks like the variable name @_STATE is causing the problem (specifically the @) so we would suggest changing the name of that variable so that it doesn't have any special characters, and re-running - hopefully that will solve the issue.

Best wishes,

Richard

Re: installation issue?

Posted: Thu Nov 20, 2014 5:44 am
by shanekav
Fixed it!

Many thanks

Shane

Re: installation issue?

Posted: Mon May 25, 2015 9:15 am
by collingwood
Hey....I am facing the same issue. May I know what procedure you have followed?

Please help...

Re: installation issue?

Posted: Tue May 26, 2015 9:47 am
by richardparker
Hi - are you able to provide any more information about the issue you have encountered? The resolution to the problem described earlier in this thread was to change the name of one of the variables in the dataset - it had a character (@) which was unsupported by Stat-JR.

Best wishes,

Richard

Re: installation issue?

Posted: Thu Mar 16, 2023 1:39 am
by plopblurt
hi collingwood, penalty kick online
Were you able to rename the variable? I applied and the error was fixed.