Closed GiorgioPresidente closed 1 year ago
@GiorgioPresidente
src/install.do
from a Stata session).program honestosqp_plugin, plugin using("honestosqp_macosx86_64.plugin")
program honestecos_plugin, plugin using("honestecos_macosx86_64.plugin")
plugin call honestosqp_plugin, _plugin_check
plugin call honestecos_plugin, _plugin_check
honestdid _plugin_check
?
I have stata/MP 15.1
If I run
do /Users/giorgiopresidente/stata-honestdid/src/install.do
I get the output below:
. if "
0'"' != "" shell make `0'
. cap noi ado uninstall honestdid criterion matches more than one package
. cap noi net uninstall honestdid criterion matches more than one package
. mata: mata clear
. mata: mata set matastrict on
. mata: mata set mataoptimize on
. cap noi mkdir src could not create directory src
. cap noi mkdir src/build could not create directory src/build
. cap noi erase src/build/lhonestdid.mlib file src/build/lhonestdid.mlib not found
. qui { file src/mata/osqp.mata not found r(601);
If I run the following, stata crashes
program honestosqp_plugin, plugin using("honestosqp_macosx86_64.plugin") program honestecos_plugin, plugin using("honestecos_macosx86_64.plugin") plugin call honestosqp_plugin, _plugin_check plugin call honestecos_plugin, _plugin_check honestdid _plugin_check
@GiorgioPresidente Please run
cd /Users/giorgiopresidente/stata-honestdid
do src/install
program honestosqp_plugin, plugin using("src/build/honestosqp_macosx86_64.plugin")
program honestecos_plugin, plugin using("src/build/honestecos_macosx86_64.plugin")
and report the output. You should not get any errors; if you do then LMK. After that's run successfully, please run
plugin call honestosqp_plugin, _plugin_check
plugin call honestecos_plugin, _plugin_check
And LMK if Stata crashes at this point.
I get four errors:
. cd /Users/giorgiopresidente/stata-honestdid /Users/giorgiopresidente/stata-honestdid
. do src/install
. if "
0'"' != "" shell make `0'
. cap noi ado uninstall honestdid criterion matches more than one package
. cap noi net uninstall honestdid criterion matches more than one package
. mata: mata clear
. mata: mata set matastrict on
. mata: mata set mataoptimize on
. cap noi mkdir src could not create directory src
. cap noi mkdir src/build could not create directory src/build
. cap noi erase src/build/lhonestdid.mlib
. qui {
. mata: mata mlib create lhonestdid, dir("src/build") replace (note: file src/build/lhonestdid.mlib not found) (file src/build/lhonestdid.mlib created)
. mata: mata mlib add lhonestdid Honest() _honest() _flci() OSQP() ECOS*(), dir("src/build") co
mplete (101 functions added)
. net install honestdid, from(`c(pwd)') replace checking honestdid consistency and verifying not already installed...
the following files will be replaced: /Users/giorgiopresidente/Library/Application Support/Stata/ado/plus/l/lhonestdid.mlib /Users/giorgiopresidente/Library/Application Support/Stata/ado/plus/h/honestdid.sthlp
installing into /Users/giorgiopresidente/Library/Application Support/Stata/ado/plus/... installation complete.
. end of do-file
. program honestosqp_plugin, plugin using("src/build/honestosqp_macosx86_64.plugin")
. program honestecos_plugin, plugin using("src/build/honestecos_macosx86_64.plugin")
@GiorgioPresidente I see; honestdid
is not getting correctly replaced. Before fixing that, though, let's check the plugin directly:
src/compile.sh
from /Users/giorgiopresidente/stata-honestdid
you didn't get any errors? If you're not sure, you can run, from a terminal,cd /Users/giorgiopresidente/stata-honestdid
git pull
bash src/compile.sh > compile.log 2>&1
and attach the log file here.
cd /Users/giorgiopresidente/stata-honestdid
program honestosqp_plugin, plugin using("src/build/honestosqp_macosx86_64.plugin")
program honestecos_plugin, plugin using("src/build/honestecos_macosx86_64.plugin")
plugin call honestosqp_plugin, _plugin_check
plugin call honestecos_plugin, _plugin_check
and LMK if Stata crashes at this point.
Last login: Wed Nov 2 18:13:40 on ttys000 giorgios-MBP:~ giorgiopresidente$ cd /Users/giorgiopresidente/stata-honestdid giorgios-MBP:stata-honestdid giorgiopresidente$ git pull remote: Enumerating objects: 36, done. remote: Counting objects: 100% (36/36), done. remote: Compressing objects: 100% (9/9), done. remote: Total 24 (delta 15), reused 21 (delta 12), pack-reused 0 Unpacking objects: 100% (24/24), done. From https://github.com/mcaceresb/stata-honestdid decf669..9b1499b main -> origin/main Updating decf669..9b1499b Fast-forward .bumpver.py | 5 - .github/workflows/main.yml | 6 +- .gitignore | 1 + README.md | 4 +- doc/honestdid.sthlp | 5 +- src/compile.sh | 15 + standalone/ecos.mata | 339 ----------------------- standalone/flci.mata | 601 ----------------------------------------- standalone/honestdid-1.1.1.zip | Bin 0 -> 3765056 bytes standalone/honestdid.mata | 490 --------------------------------- standalone/honestdid.sthlp | 5 +- standalone/osqp.mata | 223 --------------- standalone/test-replication.do | 101 ------- 13 files changed, 31 insertions(+), 1764 deletions(-) delete mode 100644 standalone/ecos.mata delete mode 100644 standalone/flci.mata create mode 100644 standalone/honestdid-1.1.1.zip delete mode 100644 standalone/honestdid.mata delete mode 100644 standalone/osqp.mata delete mode 100644 standalone/test-replication.do giorgios-MBP:stata-honestdid giorgiopresidente$ bash src/compile.sh > compile.log 2>&1
And yes, it crashes again if I run 2.
@GiorgioPresidente Can you attach the compile.log
file that should have been created in /Users/giorgiopresidente/stata-honestdid
?
I cannot find it. There is no log file
@GiorgioPresidente That's strange; in that case, can you copy/paste the output of
cd /Users/giorgiopresidente/stata-honestdid
bash src/compile.sh
here?
. cd /Users/giorgiopresidente/stata-honestdid /Users/giorgiopresidente/stata-honestdid
. bash src/compile.sh command bash is unrecognized
@GiorgioPresidente Ok, this is good news for me; it seems the compile script never ran, so I'm hoping running it will fix the issue. From a terminal, please LMK the output of
command -v make
command -v cmake
command -v sed
command -v clang
@GiorgioPresidente Actually, I just noticed that in this comment you ran the commands from Stata? Please run the code here from a terminal and LMK the output. (Same for the code here.)
1) Last login: Wed Nov 2 19:13:11 on ttys000 giorgios-MBP:~ giorgiopresidente$ cd /Users/giorgiopresidente/stata-honestdid giorgios-MBP:stata-honestdid giorgiopresidente$ bash src/compile.sh cmake executable not found giorgios-MBP:stata-honestdid giorgiopresidente$
2)
Last login: Wed Nov 2 19:35:55 on ttys000 giorgios-MBP:~ giorgiopresidente$ command -v make /usr/bin/make giorgios-MBP:~ giorgiopresidente$ command -v cmake giorgios-MBP:~ giorgiopresidente$ command -v sed /usr/bin/sed giorgios-MBP:~ giorgiopresidente$ command -v clang /usr/bin/clang giorgios-MBP:~ giorgiopresidente$
I have installed it but I suspect I have to do something else:
Last login: Wed Nov 2 19:41:34 on ttys000 giorgios-MBP:~ giorgiopresidente$ cd /Users/giorgiopresidente/stata-honestdid giorgios-MBP:stata-honestdid giorgiopresidente$ bash src/compile.sh cmake executable not found giorgios-MBP:stata-honestdid giorgiopresidente$
@GiorgioPresidente If you have it installed and it's not finding it then it's not in your path, I reckon. Where did you install it? (PS: You can check your path by running echo $PATH
from a terminal.)
cmake is in my application folder. If I run echo $PATH, I get
giorgios-MBP:~ giorgiopresidente$ echo $PATH /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin
OK I made progresses. I managed to run the below
Last login: Thu Nov 3 07:56:40 on ttys000
giorgios-MBP:~ giorgiopresidente$ sudo "/Applications/CMake.app/Contents/bin/cmake-gui" --install
Password:
Linked: '/usr/local/bin/cmake' -> '/Applications/CMake.app/Contents/bin/cmake'
Linked: '/usr/local/bin/ctest' -> '/Applications/CMake.app/Contents/bin/ctest'
Linked: '/usr/local/bin/cpack' -> '/Applications/CMake.app/Contents/bin/cpack'
Linked: '/usr/local/bin/cmake-gui' -> '/Applications/CMake.app/Contents/bin/cmake-gui'
Linked: '/usr/local/bin/ccmake' -> '/Applications/CMake.app/Contents/bin/ccmake'
giorgios-MBP:~ giorgiopresidente$ cd /Users/giorgiopresidente/stata-honestdid
giorgios-MBP:stata-honestdid giorgiopresidente$ bash src/compile.sh
Running as APPLE_X86_64 (Darwin x86_64)
Cloning into 'ecos'...
remote: Enumerating objects: 5984, done.
remote: Counting objects: 100% (66/66), done.
remote: Compressing objects: 100% (41/41), done.
remote: Total 5984 (delta 29), reused 48 (delta 25), pack-reused 5918
Receiving objects: 100% (5984/5984), 33.33 MiB | 5.60 MiB/s, done.
Resolving deltas: 100% (2763/2763), done.
Cloning into 'osqp'...
remote: Enumerating objects: 24959, done.
remote: Counting objects: 100% (822/822), done.
remote: Compressing objects: 100% (349/349), done.
remote: Total 24959 (delta 515), reused 722 (delta 447), pack-reused 24137
Receiving objects: 100% (24959/24959), 45.23 MiB | 4.93 MiB/s, done.
Resolving deltas: 100% (16965/16965), done.
Submodule 'lin_sys/direct/qdldl/qdldl_sources' (https://github.com/osqp/qdldl.git) registered for path 'lin_sys/direct/qdldl/qdldl_sources'
Cloning into '/Users/giorgiopresidente/stata-honestdid/osqp/lin_sys/direct/qdldl/qdldl_sources'...
remote: Enumerating objects: 770, done.
remote: Counting objects: 100% (219/219), done.
remote: Compressing objects: 100% (20/20), done.
remote: Total 770 (delta 201), reused 202 (delta 199), pack-reused 551
Receiving objects: 100% (770/770), 142.79 KiB | 3.17 MiB/s, done.
Resolving deltas: 100% (401/401), done.
Submodule path 'lin_sys/direct/qdldl/qdldl_sources': checked out '7d16b70a10a152682204d745d814b6eb63dc5cd2'
Compiling ECOS plugin
( cd external/ldl ; /Library/Developer/CommandLineTools/usr/bin/make clean )
rm -f .o .obj .ln .bb .bbg .da .tcov .gcov gmon.out .bak .d .gcda .gcno libecos.a libecos.so libecos.dylib libecos.dll ecos_bb_test ecostester ecostester.exe runecosexp
( cd external/amd ; /Library/Developer/CommandLineTools/usr/bin/make clean )
rm -f .o .obj .ln .bb .bbg .da .tcov .gcov gmon.out .bak .d .gcda .gcno libecos.a libecos.so libecos.dylib libecos.dll ecos_bb_test ecostester ecostester.exe runecosexp
rm -f .o .obj .ln .bb .bbg .da .tcov .gcov gmon.out .bak .d .gcda .gcno libecos.a libecos.so libecos.dylib libecos.dll ecos_bb_test ecostester ecostester.exe runecosexp
( cd external/ldl ; /Library/Developer/CommandLineTools/usr/bin/make purge )
rm -f libldl.a
( cd external/amd ; /Library/Developer/CommandLineTools/usr/bin/make purge )
rm -f libamd.a libamdf77.a
rm -f libecos.a libecos_bb.a runecos runecosexp
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/ecos.c -o ecos.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/kkt.c -o kkt.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/cone.c -o cone.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/spla.c -o spla.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/ctrlc.c -o ctrlc.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/timer.c -o timer.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/preproc.c -o preproc.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/splamm.c -o splamm.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/equil.c -o equil.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/expcone.c -o expcone.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c src/wright_omega.c -o wright_omega.o
( cd external/ldl ; /Library/Developer/CommandLineTools/usr/bin/make )
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -I../SuiteSparse_config -Iinclude -c src/ldl.c -o ldl.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -I../SuiteSparse_config -Iinclude -DLDL_LONG -c src/ldl.c -o ldll.o
ar rcs libldl.a ldl.o ldll.o
ranlib libldl.a
ar -x external/ldl/libldl.a
( cd external/amd ; /Library/Developer/CommandLineTools/usr/bin/make )
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -c src/amd_global.c -o amd_global.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_aat.c -o amd_i_aat.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_1.c -o amd_i_1.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_2.c -o amd_i_2.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_dump.c -o amd_i_dump.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_postorder.c -o amd_i_postorder.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_post_tree.c -o amd_i_post_tree.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_defaults.c -o amd_i_defaults.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_order.c -o amd_i_order.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_control.c -o amd_i_control.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_info.c -o amd_i_info.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_valid.c -o amd_i_valid.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDINT -c src/amd_preprocess.c -o amd_i_preprocess.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_aat.c -o amd_l_aat.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_1.c -o amd_l_1.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_2.c -o amd_l_2.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_dump.c -o amd_l_dump.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_postorder.c -o amd_l_postorder.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_post_tree.c -o amd_l_post_tree.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_defaults.c -o amd_l_defaults.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_order.c -o amd_l_order.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_control.c -o amd_l_control.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_info.c -o amd_l_info.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_valid.c -o amd_l_valid.o
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -I../SuiteSparse_config -DDLONG -c src/amd_preprocess.c -o amd_l_preprocess.o
ar rcs libamd.a amd_global.o amd_i_aat.o amd_i_1.o amd_i_2.o amd_i_dump.o amd_i_postorder.o amd_i_post_tree.o amd_i_defaults.o amd_i_order.o amd_i_control.o amd_i_info.o amd_i_valid.o amd_i_preprocess.o amd_l_aat.o amd_l_1.o amd_l_2.o amd_l_dump.o amd_l_postorder.o amd_l_post_tree.o amd_l_defaults.o amd_l_order.o amd_l_control.o amd_l_info.o amd_l_valid.o amd_l_preprocess.o
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libamd.a(amd_i_dump.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libamd.a(amd_l_dump.o) has no symbols
ranlib libamd.a
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libamd.a(amd_i_dump.o) has no symbols
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libamd.a(amd_l_dump.o) has no symbols
ar -x external/amd/libamd.a
ar rcs libecos.a ecos.o kkt.o cone.o spla.o ctrlc.o timer.o preproc.o splamm.o equil.o expcone.o wright_omega.o ldll.o amd_l.o amd_global.o
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libecos.a(amd_l_dump.o) has no symbols
ranlib libecos.a
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libecos.a(amd_l_dump.o) has no symbols
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c ecos_bb/ecos_bb_preproc.c -o ecos_bb_preproc.o
In file included from ecos_bb/ecos_bb_preproc.c:30:
include/ecos_bb.h:205:15: warning: unused function 'get_bool_node_id'
[-Wunused-function]
static char get_bool_node_id(idxint idx, ecos_bb_pwork prob)
^
include/ecos_bb.h:210:17: warning: unused function 'get_int_node_id'
[-Wunused-function]
static pfloat get_int_node_id(idxint idx, ecos_bb_pwork prob)
^
include/ecos_bb.h:220:16: warning: unused function 'pfloat_round'
[-Wunused-function]
static pfloat pfloat_round(pfloat number)
^
include/ecos_bb.h:225:16: warning: unused function 'pfloat_ceil'
[-Wunused-function]
static pfloat pfloat_ceil(pfloat number, pfloat integer_tol)
^
include/ecos_bb.h:230:16: warning: unused function 'pfloat_floor'
[-Wunused-function]
static pfloat pfloat_floor(pfloat number, pfloat integer_tol)
^
include/ecos_bb.h:235:16: warning: unused function 'float_eqls'
[-Wunused-function]
static idxint float_eqls(pfloat a, pfloat b, pfloat integer_tol)
^
6 warnings generated.
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -c ecos_bb/ecos_bb.c -o ecos_bb.o
ecos_bb/ecos_bb.c:681:118: warning: unused parameter 'node_idx'
[-Wunused-parameter]
...problem, idxint split_idx, pfloat split_val, idxint node_idx)
^
ecos_bb/ecos_bb.c:46:13: warning: unused function 'print_ecos_solution'
[-Wunused-function]
static void print_ecos_solution(ecos_bb_pwork prob)
^
ecos_bb/ecos_bb.c:55:13: warning: unused function 'print_ecos_xequil'
[-Wunused-function]
static void print_ecos_xequil(ecos_bb_pwork prob)
^
ecos_bb/ecos_bb.c:68:13: warning: unused function 'print_ecos_h'
[-Wunused-function]
static void print_ecos_h(ecos_bb_pwork prob)
^
ecos_bb/ecos_bb.c:77:13: warning: unused function 'print_ecos_c'
[-Wunused-function]
static void print_ecos_c(ecos_bb_pwork prob)
^
ecos_bb/ecos_bb.c:86:13: warning: unused function 'print_node'
[-Wunused-function]
static void print_node(ecos_bb_pwork prob, idxint i)
^
ecos_bb/ecos_bb.c:112:13: warning: unused function 'print_stats'
[-Wunused-function]
static void print_stats(ecos_bb_pwork prob)
^
7 warnings generated.
ar rcs libecos_bb.a ecos.o kkt.o cone.o spla.o ctrlc.o timer.o preproc.o splamm.o equil.o expcone.o wright_omega.o ecos_bb_preproc.o ecos_bb.o ldll.o amd_l*.o amd_global.o
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libecos_bb.a(amd_l_dump.o) has no symbols
ranlib libecos_bb.a
/Library/Developer/CommandLineTools/usr/bin/ranlib: file: libecos_bb.a(amd_l_dump.o) has no symbols
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -o runecos src/runecos.c libecos.a -lm
echo ECOS successfully built. Type ./runecos to run demo problem.
ECOS successfully built. Type ./runecos to run demo problem.
clang -O2 -Wall -DCTRLC=1 -Wextra -fPIC -DLDL_LONG -DDLONG -arch x86_64 -Iinclude -Iexternal/ldl/include -Iexternal/amd/include -Iexternal/SuiteSparse_config -o runecosexp src/runecos_exp.c libecos.a -lm
echo ECOS-Exp successfully built. Type ./runecosexp to run demo problem.
ECOS-Exp successfully built. Type ./runecosexp to run demo problem.
Compiling OSQP plugin
-- The C compiler identification is AppleClang 10.0.0.10001044
-- The CXX compiler identification is AppleClang 10.0.0.10001044
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /Library/Developer/CommandLineTools/usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Library/Developer/CommandLineTools/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- We are on a Darwin system
-- Embedded is OFF
-- Printing is ON
-- Profiling is ON
-- User interrupt is ON
-- Floats are OFF
-- Long integers (64bit) are ON
-- Code coverage is OFF
-- MKL Pardiso: ON
-- Floats are OFF
-- Long integers (64bit) are ON
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/giorgiopresidente/stata-honestdid/osqp/build
[ 1%] Building C object lin_sys/direct/qdldl/qdldl_sources/CMakeFiles/qdldlobject.dir/src/qdldl.c.o
[ 1%] Built target qdldlobject
[ 3%] Building C object lin_sys/direct/CMakeFiles/linsys_pardiso.dir/pardiso/pardiso_interface.c.o
[ 5%] Building C object lin_sys/direct/CMakeFiles/linsys_pardiso.dir/pardiso/pardiso_loader.c.o
[ 5%] Built target linsys_pardiso
[ 7%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_1.c.o
[ 9%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_2.c.o
[ 11%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_aat.c.o
[ 13%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_control.c.o
[ 15%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_defaults.c.o
[ 17%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_info.c.o
[ 19%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_order.c.o
[ 21%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_post_tree.c.o
[ 23%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_postorder.c.o
[ 25%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_preprocess.c.o
[ 26%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/amd_valid.c.o
[ 28%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/amd/src/SuiteSparse_config.c.o
[ 30%] Building C object lin_sys/direct/qdldl/CMakeFiles/linsys_qdldl.dir/qdldl_interface.c.o
[ 30%] Built target linsys_qdldl
[ 32%] Building C object CMakeFiles/osqpstatic.dir/src/auxil.c.o
[ 34%] Building C object CMakeFiles/osqpstatic.dir/src/error.c.o
[ 36%] Building C object CMakeFiles/osqpstatic.dir/src/lin_alg.c.o
[ 38%] Building C object CMakeFiles/osqpstatic.dir/src/osqp.c.o
[ 40%] Building C object CMakeFiles/osqpstatic.dir/src/proj.c.o
[ 42%] Building C object CMakeFiles/osqpstatic.dir/src/scaling.c.o
[ 44%] Building C object CMakeFiles/osqpstatic.dir/src/util.c.o
[ 46%] Building C object CMakeFiles/osqpstatic.dir/src/kkt.c.o
[ 48%] Building C object CMakeFiles/osqpstatic.dir/src/cs.c.o
[ 50%] Building C object CMakeFiles/osqpstatic.dir/src/polish.c.o
[ 51%] Building C object CMakeFiles/osqpstatic.dir/src/lin_sys.c.o
[ 53%] Building C object CMakeFiles/osqpstatic.dir/src/ctrlc.c.o
[ 55%] Building C object CMakeFiles/osqpstatic.dir/lin_sys/lib_handler.c.o
[ 57%] Linking C static library out/libosqp.a
[ 57%] Built target osqpstatic
[ 59%] Building C object CMakeFiles/osqp.dir/src/auxil.c.o
[ 61%] Building C object CMakeFiles/osqp.dir/src/error.c.o
[ 63%] Building C object CMakeFiles/osqp.dir/src/lin_alg.c.o
[ 65%] Building C object CMakeFiles/osqp.dir/src/osqp.c.o
[ 67%] Building C object CMakeFiles/osqp.dir/src/proj.c.o
[ 69%] Building C object CMakeFiles/osqp.dir/src/scaling.c.o
[ 71%] Building C object CMakeFiles/osqp.dir/src/util.c.o
[ 73%] Building C object CMakeFiles/osqp.dir/src/kkt.c.o
[ 75%] Building C object CMakeFiles/osqp.dir/src/cs.c.o
[ 76%] Building C object CMakeFiles/osqp.dir/src/polish.c.o
[ 78%] Building C object CMakeFiles/osqp.dir/src/lin_sys.c.o
[ 80%] Building C object CMakeFiles/osqp.dir/src/ctrlc.c.o
[ 82%] Building C object CMakeFiles/osqp.dir/lin_sys/lib_handler.c.o
[ 84%] Linking C shared library out/libosqp.dylib
[ 84%] Built target osqp
[ 86%] Building C object CMakeFiles/osqp_demo.dir/examples/osqp_demo.c.o
[ 88%] Linking C executable out/osqp_demo
[ 88%] Built target osqp_demo
[ 90%] Building C object lin_sys/direct/qdldl/qdldl_sources/CMakeFiles/qdldlstatic.dir/src/qdldl.c.o
[ 92%] Linking C static library out/libqdldl.a
[ 92%] Built target qdldlstatic
[ 94%] Building C object lin_sys/direct/qdldl/qdldl_sources/CMakeFiles/qdldl.dir/src/qdldl.c.o
[ 96%] Linking C shared library out/libqdldl.dylib
[ 96%] Built target qdldl
[ 98%] Building C object lin_sys/direct/qdldl/qdldl_sources/CMakeFiles/qdldl_example.dir/examples/example.c.o
[100%] Linking C executable out/qdldl_example
[100%] Built target qdldl_example
Compiling honestdid plugin
with flags -bundle -DSYSTEM=APPLEMAC -arch x86_64
with opts OSQP_OUT=src/build/honestosqp_macosx86_64.plugin ECOS_OUT=src/build/honestecos_macosx86_64.plugin GCC=clang
rm -f src/build/honestosqp_macosx86_64.plugin src/build/honestecos_macosx86_64.plugin
clang -Wall -O3 -bundle -DSYSTEM=APPLEMAC -arch x86_64 -I./osqp/include -o src/build/honestosqp_macosx86_64.plugin src/plugin/honestosqp.c src/plugin/stplugin.c ./osqp/build/out/libosqp.a
clang -Wall -O3 -bundle -DSYSTEM=APPLEMAC -arch x86_64 -DLDL_LONG -DDLONG -I./ecos/include -I./ecos/external/SuiteSparse_config -o src/build/honestecos_macosx86_64.plugin src/plugin/honestecos.c src/plugin/stplugin.c ./ecos/libecos.a ./ecos/libecos_bb.a
Overriding OSX plugin with locally compiled plugin
giorgios-MBP:stata-honestdid giorgiopresidente$
@GiorgioPresidente Great! That all looks correct to me. Can you try this again now the plugin is locally compiled? From a fresh Stata session:
cd /Users/giorgiopresidente/stata-honestdid
program honestosqp_plugin, plugin using("src/build/honestosqp_macosx86_64.plugin")
program honestecos_plugin, plugin using("src/build/honestecos_macosx86_64.plugin")
plugin call honestosqp_plugin, _plugin_check
plugin call honestecos_plugin, _plugin_check
and hopefully it doesn't crash now.
. cd /Users/giorgiopresidente/stata-honestdid /Users/giorgiopresidente/stata-honestdid
. program honestosqp_plugin, plugin using("src/build/honestosqp_macosx86_64.plugin")
. program honestecos_plugin, plugin using("src/build/honestecos_macosx86_64.plugin")
. plugin call honestosqp_plugin, _plugin_check (note: honestosqp_plugin v1.1.1 successfully loaded)
. plugin call honestecos_plugin, _plugin_check (note: honestecos_plugin v1.1.1 successfully loaded)
But unfortunately keeps crashing when invoking honestdid...
@GiorgioPresidente Yes, that it would continue to crash at this point makes sense since I saw here that you have multiple honestdid
installs. Let's deal with that first.
Run net uninstall honestdid
from any Stata session. It should give you a list of the existing honestdid
installations along with a numeric tag.
Uninstall each tag individually
net uninstall [1]
net uninstall [2]
// etc
You will have to replace [1]
, [2]
, etc. with whatever Stata gives you.
cd /Users/giorgiopresidente/stata-honestdid
do src/install
Now this shouldn't give any errors.
cd /Users/giorgiopresidente/stata-honestdid
shell shasum src/build/honestosqp_macosx86_64.plugin
findfile honestosqp_macosx.plugin
shell shasum `r(fn)'
shell shasum src/build/honestecos_macosx86_64.plugin
findfile honestecos_macosx.plugin
shell shasum `r(fn)'
The shasum output by each pair of shell commands should be the same. If it is then the plugin reinstalled correctly, and you should be able to use honestdid
. However, if it crashes yet again LMK.
Success!! Thanks so much!
Hi, thanks a lot for writing the command!
I had an exchange with Jonathan on twitter for a problem with the package. Please see below.
Best Giorgio
My system info:
MacBook Pro (13-inch, 2017, Four Thunderbolt 3 Ports) 3,5 GHz Intel Core i7 16 GB 2133 MHz LPDDR3 Intel Iris Plus Graphics 650 1536 MB
I have followed the following steps:
1) open stata and installed with the command
local github https://raw.githubusercontent.com net install honestdid, from(`github'/mcaceresb/stata-honestdid/main) replace
2) run the medicaid expansion example:
Install here coefplot, ftools, reghdfe, plot scheme local github https://raw.githubusercontent.com ssc install coefplot, replace ssc install ftools, replace ssc install reghdfe, replace net install scheme-modern, replace from(`github'/mdroste/stata-scheme-modern/master) set scheme modern
Load data local mixtape https://raw.githubusercontent.com/Mixtape-Sessions use `mixtape'/Advanced-DID/main/Exercises/Data/ehec_data.dta, clear l in 1/5
Keep years before 2016. Drop the 2016 cohort keep if (year < 2016) & (missing(yexp2) | (yexp2 != 2015))
Create a treatment dummy gen byte D = (yexp2 == 2014) gen `:type year' Dyear = cond(D, year, 2013)
Run the TWFE spec reghdfe dins b2013.Dyear, absorb(stfips year) cluster(stfips) noconstant
local plotopts ytitle("Estimate and 95% Conf. Int.") title("Effect on dins") coefplot, vertical yline(0) ciopts(recast(rcap)) xlabel(,angle(45)) `plotopts'
which delivers the expected output.
3) then I run
honestdid, pre(1/5) post(7/8) mvec(0.5(0.5)2)
and stata crashes. It crashes even if I only type honestdid without anything else. I have also tried running the following from the terminal
git clone https://github.com/mcaceresb/stata-honestdid cd stata-honestdid bash src/compile.sh
and then re-running the example, with no success.