Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nonlinear estimation #87

Open
wants to merge 544 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
544 commits
Select commit Hold shift + click to select a range
cf6ed73
fix bicgstab sylvester for sparse C
Sep 19, 2024
6aaa658
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
Sep 19, 2024
9f7eca4
precond not reliably better, prob reduction not possible
thorek1 Sep 20, 2024
dc6d4f9
more timings
thorek1 Sep 20, 2024
94477aa
fix type compatibility for sylvester calls
thorek1 Sep 20, 2024
bb540b8
early terminate compression if masks are effectively 0
Sep 20, 2024
cdf6eb9
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
Sep 20, 2024
ae561da
less sparsity
Sep 20, 2024
f0b518c
trying to get the matrices smaller. not correct so far
thorek1 Sep 20, 2024
5997981
correct but no chance for large models
thorek1 Sep 20, 2024
6401c27
correct
thorek1 Sep 20, 2024
da7fefe
2nd order estim script
Sep 21, 2024
3561952
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
Sep 21, 2024
9209353
rrule filter fails if no match found
Sep 21, 2024
4f51004
NSSS timers
thorek1 Sep 21, 2024
752658f
inversion filter timings
thorek1 Sep 21, 2024
5552959
fix jet 1.11 tests
thorek1 Sep 21, 2024
08d52ec
fix dual get NSSS call
Sep 22, 2024
82bd31b
more todos
Sep 22, 2024
e32b6c3
estim script 2nd order
Sep 22, 2024
61a3dae
minor comments and changes
thorek1 Sep 22, 2024
0b82f10
rewrote matmultkron
thorek1 Sep 22, 2024
bb8eae8
optim mat mult kron
thorek1 Sep 22, 2024
6c85571
tried sparse return matmultkron;->nohelp. comments and faster post pr…
thorek1 Sep 22, 2024
e5422b3
type stability for matmultkron (catch Duals)
thorek1 Sep 22, 2024
8973dff
try catch sylvd
Sep 23, 2024
eae4ae9
download us data from FRED
Sep 23, 2024
3c1f676
gradual finding of initial value
Sep 24, 2024
4e50a68
add priors switch to allow for all params to e estimated
Sep 24, 2024
e379c3c
rechecked data download
thorek1 Sep 25, 2024
34feded
fallback in ENV not set
thorek1 Sep 25, 2024
e7e2a8b
custom settings at after ENV
thorek1 Sep 25, 2024
6843a31
less allocs second order inversion filter
thorek1 Sep 25, 2024
8642ec6
optim second order llh pullback
thorek1 Sep 25, 2024
a7211ca
cleanup timings
thorek1 Sep 25, 2024
c0b2cfa
fixed pruned 2nd order pullback
thorek1 Sep 25, 2024
10aa827
new inits, back to half of n cpu threads
thorek1 Sep 25, 2024
9a3b41b
new inits fo estim
Sep 26, 2024
1ccf939
folder naming update
Sep 26, 2024
9bb640f
dont use initial params in the begining
Sep 26, 2024
5c84e96
estimation results subfolder
Sep 26, 2024
eeeed01
fix paths
Sep 26, 2024
d4ccdc3
initialise with SA
Sep 26, 2024
a8940fb
switch for geo and sampler
thorek1 Sep 27, 2024
a45910e
different initial value strategy
Sep 27, 2024
5628386
add EA data script
Sep 27, 2024
ec9a2bd
use gauss newton for steady state in estimation
Sep 27, 2024
04f2c7e
redo tols in SS solver
Sep 27, 2024
8462e47
nelder mead instead of SA and open priors
Sep 27, 2024
687ed38
EA data with hours growth
Sep 27, 2024
2e0cbb7
gauss newton for NSSS warm starts and refined tols
Sep 28, 2024
0248af5
fix varnames
Sep 28, 2024
8cdbe8d
compresse kron3 with resize
Sep 30, 2024
962788d
check whether KF remains finite
Sep 30, 2024
05e0ec8
add SW07 model with dlabobs
Sep 30, 2024
810091c
add hours_worked_growth to US data download
Sep 30, 2024
c79b333
include dlabobs in EA data download script
Sep 30, 2024
f86c565
add labor switch (rgowth/level)
Sep 30, 2024
ab8886a
update compat and DI calls
thorek1 Sep 30, 2024
abf4127
catch case where sol_minimum is already very small
thorek1 Sep 30, 2024
32785ac
rm NLopt restriction
thorek1 Sep 30, 2024
b410413
do ubuntu runners until fix
thorek1 Sep 30, 2024
373f723
tested MCHMC
Sep 30, 2024
d965079
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
Sep 30, 2024
497919c
robust lbfgs init
Sep 30, 2024
6d72fe9
more robust inits
Sep 30, 2024
ff2f85e
clean up and fix initialisation
Sep 30, 2024
26cfdc6
more robust init
Sep 30, 2024
bcd7990
include measurement error
Sep 30, 2024
cce49e0
fix varnames
Sep 30, 2024
ef5c23d
timings for lyapunov
Oct 1, 2024
0eb6b2d
timings for 1st order sol and fix higher order
Oct 1, 2024
ed993af
fix jacct
Oct 1, 2024
f529a6f
lower tol on measurement errors, robust gradual init finding
Oct 1, 2024
0f605e8
add separate model and config for measurement error
Oct 2, 2024
e22650c
no init but longer NUTS adaptation phase
Oct 2, 2024
b4462f8
add ea raw data
Oct 2, 2024
a95756c
rescale measurement error shocks
thorek1 Oct 2, 2024
b220058
reactivate init finder
thorek1 Oct 2, 2024
29c83a8
use the initial params found
Oct 2, 2024
9e43496
1000 adaptation steps
Oct 2, 2024
988db0a
gamma priors for taylor rule (avoid negative values)
Oct 2, 2024
e5c2ac6
hard coded starting values
Oct 2, 2024
737e3e3
todos estimation
thorek1 Oct 2, 2024
5a99e95
add no labor option for estim
thorek1 Oct 2, 2024
b0f18c3
carry over found params only if LLH is finite, same for sampler init
Oct 2, 2024
f7f75aa
more robust mat mul and fact
Oct 3, 2024
1177527
constelab also in case of dlabobs
Oct 3, 2024
762e28c
eplicit inits
Oct 3, 2024
ffa8d7b
early return inf if not solved for 1st,2nd,3rd order sols
Oct 4, 2024
0439ee1
verbose error messages during solve process
Oct 4, 2024
3ea94ba
verbosity in the filters
Oct 4, 2024
51bbde9
NSSS early termination, count func and grad calls, verbose option
Oct 4, 2024
f37f6dc
fix type instability
thorek1 Oct 4, 2024
50a35ec
fix type instability
thorek1 Oct 4, 2024
94c463a
fix forward diff errors in get NSSS
thorek1 Oct 4, 2024
eed3a53
try warm start with both GN and LM before starting points
thorek1 Oct 5, 2024
6344995
init params that work for EA 2nd order
Oct 5, 2024
7d1dfa2
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
Oct 5, 2024
318fa50
back to only gauss newton. check whether that fixes test errors
thorek1 Oct 6, 2024
def8739
callback, init params and sections
Oct 6, 2024
f70c9c0
no print in callback
Oct 6, 2024
a59cfbf
fin grad is local in test models
Oct 6, 2024
b6a6423
adjust NSSS convergence tol and more error messages
Oct 6, 2024
23a313b
also have LM solve warm starts to fix tests
Oct 6, 2024
4545cea
GN stops if it increases
Oct 6, 2024
408ba0e
adjust tol on NSSS solver
Oct 6, 2024
165493f
change back tol as tests started failing
Oct 6, 2024
6501b7d
adjusting tols and termination criteria for LM
Oct 6, 2024
077e28f
fixed NSSS solver
Oct 6, 2024
e148776
correct func eval counter in LM
Oct 6, 2024
596ff45
adjust tol again so test work
Oct 6, 2024
2657207
more starting points
Oct 6, 2024
60ae0ec
dont pass on NaNs
Oct 6, 2024
4f85d68
back to previous fast tol criteria for NSSS solver
Oct 6, 2024
f617df1
fix loose end
Oct 6, 2024
c41ce8e
fix xtol in GN
Oct 6, 2024
7ba6d02
fix tol again
Oct 6, 2024
4834b9e
init without optim
Oct 6, 2024
bb5e495
separate scripts for filters and algos
Oct 7, 2024
0a57ba4
move more to specific scripts
Oct 7, 2024
6040d89
fixed first order inversion filter for decomposition
Oct 7, 2024
e709e61
second order inversion filter
Oct 7, 2024
f1eaac0
pruned second order inversion filter
Oct 7, 2024
2617a08
third order inversion filter
Oct 7, 2024
7b57260
fix higher order plotting
Oct 7, 2024
96d5eef
pruned third order inversion filter
Oct 7, 2024
55a67de
deleted dead code
Oct 7, 2024
e06a514
fix plotting
Oct 7, 2024
df970a8
type preventing tests to pass
Oct 7, 2024
8803b36
new int params and use optim again before sampling
Oct 7, 2024
39e0549
add pigeons
thorek1 Oct 8, 2024
708d849
prior bounds
Oct 8, 2024
1c7e937
back to no bounds
thorek1 Oct 8, 2024
edf2525
pigeons rounds
Oct 8, 2024
6d3691b
new starting point and wider priors for msrmt errors
Oct 8, 2024
f1b13ae
fix msrmnt error inits
Oct 8, 2024
71891c2
stricter tol for NSSS
Oct 8, 2024
a616a3a
todos, pigeons no multithreading
Oct 8, 2024
3e1aac1
switch to 1.11
Oct 8, 2024
fd42817
add 1.10 runner
Oct 8, 2024
56edcf6
catch failed matrix inversion
Oct 9, 2024
f146b75
labor average 2000-2020 substracted
Oct 9, 2024
705a952
add Cauchy prior
Oct 9, 2024
56a785c
fix msmt error parameters in prior
Oct 9, 2024
b692991
switch to half cauchy priors for variance and estimate on 1990-today …
Oct 9, 2024
ee14544
actch svd failures in inversion filter
Oct 9, 2024
19e1d9e
export cauchy dist
Oct 9, 2024
0528609
add analysis scripts
Oct 9, 2024
4fffc1c
continue 1 more rounds with pigeons
Oct 10, 2024
707e843
wrong condition for checkpoint
Oct 10, 2024
69ab7e1
tighter msmt error prior, other inits
Oct 11, 2024
0b5d7a9
faster factorization in riccati
thorek1 Oct 11, 2024
dad6d9c
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
thorek1 Oct 11, 2024
5ab8807
separate out nonlinear solvers
thorek1 Oct 12, 2024
e03c3dc
separate out code and generalise 1st order sol
thorek1 Oct 13, 2024
40af251
indexin instead of findall
thorek1 Oct 13, 2024
fb77cda
fix 1st order
thorek1 Oct 13, 2024
820957a
wrote AD for qme centric first order sol
thorek1 Oct 15, 2024
f6714ad
simplify alternative first order methods
thorek1 Oct 15, 2024
73b2f5e
doubling test script
thorek1 Oct 15, 2024
402e638
fix typo
Oct 15, 2024
70cf903
rm explosive keyword
Oct 15, 2024
08d1958
early return in sol could not be found
Oct 15, 2024
178d94a
add other qme algos
thorek1 Oct 15, 2024
db109a9
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
thorek1 Oct 15, 2024
5ac6483
add qme initial guess (incomplete)
Oct 15, 2024
fa610e9
Merge branch 'nonlinear-estimation' of https://github.com/thorek1/Mac…
Oct 15, 2024
2afab2c
1st order starting points
Oct 15, 2024
36b9a4e
kalmna filter starting point
Oct 15, 2024
c2fba1d
fix perturbation dual
Oct 15, 2024
db11cc4
verbose first order
Oct 15, 2024
158837e
more informative message from qme solvers
Oct 15, 2024
a0e03bc
verbose first order
Oct 15, 2024
e71d4e5
fix tests
Oct 15, 2024
4c82788
get_llh with qme solver input, more verbosity
Oct 15, 2024
21954e7
estimation with schur by default
Oct 15, 2024
436e659
try doubling again with fixed init vals
thorek1 Oct 15, 2024
5f4976a
back to schur as default
thorek1 Oct 15, 2024
e737fcb
llh schur
thorek1 Oct 16, 2024
956cd65
lower tol on qme doubling
thorek1 Oct 16, 2024
e0547bb
back to doubling after having fixed initial guess
thorek1 Oct 16, 2024
93f873b
if doubling fails, try schur
thorek1 Oct 16, 2024
534e065
allow earlier termination of sylvester doubling
thorek1 Oct 16, 2024
b164d5a
back to schur
thorek1 Oct 16, 2024
5708ef2
back to doubling but with skipping calcl if tol already reached on or…
thorek1 Oct 16, 2024
9717e41
verbosity in filters
thorek1 Oct 16, 2024
f0ac580
lyapunov with more frequent check of result
thorek1 Oct 16, 2024
fa7c073
sylvester with intial guess argument
thorek1 Oct 16, 2024
e4e9325
higher order solution funcs return compressed solution which is cache…
thorek1 Oct 16, 2024
8c3b6fe
fix tests and eltype
thorek1 Oct 16, 2024
fc4a9f9
tol not taken over from perturbation funcs (use defaults instead)
thorek1 Oct 16, 2024
0ccac3c
sylvester verbose and initial values, different convergence criteria
thorek1 Oct 16, 2024
95ce85e
ci on 1.11.0 only since 1.11.1 fails due to pigeons
thorek1 Oct 16, 2024
216d9a5
fix jet test
Oct 17, 2024
f03acf8
fix higher order perturbation object again
Oct 17, 2024
e33db91
higher tol on previous solution for qme
Oct 17, 2024
7a40bd3
higher qme tol on previous sol
Oct 17, 2024
5dfd6d8
verbose get_llh in test models
Oct 17, 2024
0f65a4f
robust findiff sw07
Oct 17, 2024
94ee373
only save qme sol if successfully solved
Oct 17, 2024
74fdebe
verbose schur
Oct 17, 2024
b67c81d
save sylvester results only when converged
Oct 17, 2024
a2b5ab3
more efficient qme doubling
Oct 17, 2024
7a9550b
sylvester restart with zero initial guess
Oct 17, 2024
9c1f6e1
fix qme
Oct 17, 2024
9cfdfa4
lower qme tol so that test pass
Oct 17, 2024
5d5fda7
verbose 1st order sol; fix forwarddiff first order
Oct 17, 2024
1efcab6
use sylvester solver for forwarddiff; otherwise there is a mess with …
Oct 17, 2024
177442c
more robust fin grad
Oct 17, 2024
6e960b8
more robust initialisation for sw07 estimation
Oct 17, 2024
5ed183c
no initialisation sw07 estim
Oct 17, 2024
2785706
fix fin grad again
Oct 17, 2024
a3ab4f1
back to 1.11 in ci
thorek1 Oct 17, 2024
fb1676a
no mode for sw07 estim
thorek1 Oct 17, 2024
e18c358
fix runtests quad iter
thorek1 Oct 17, 2024
9f86c54
no revise
thorek1 Oct 17, 2024
43cfb07
no JET on 1.12+
thorek1 Oct 18, 2024
f0069ce
update dynamicppl compat
Oct 18, 2024
b9c4ea9
solve 1st order dual sylveter equation with bicgstab because it is mo…
thorek1 Oct 18, 2024
27bf7c3
estimation on mac runners
thorek1 Oct 18, 2024
e4ffb64
fix moment derivs failing due to sylvester tol (bicgstab achieves hig…
thorek1 Oct 18, 2024
69ebfb3
fallback to bicgstab for sylvester equation
thorek1 Oct 18, 2024
ee6a3b2
define types for moments
thorek1 Oct 18, 2024
6950510
fix types in moment script
thorek1 Oct 19, 2024
a364e20
Fix types again
thorek1 Oct 19, 2024
de8e182
mean returns solved flag
thorek1 Oct 19, 2024
06e434c
fix spzeros
thorek1 Oct 20, 2024
e4ff5aa
fix calc mean again
thorek1 Oct 20, 2024
8ec6edb
more robust lyapunov and sylvester solver
thorek1 Oct 20, 2024
860c47c
better tol qme
thorek1 Oct 20, 2024
9165e06
fix tol and robust lyapunov
thorek1 Oct 20, 2024
c8b1eec
better verbose messages qme
thorek1 Oct 20, 2024
42ebad0
more refined robustness criteria
thorek1 Oct 20, 2024
5bc3107
fix tol and refinement conditions
thorek1 Oct 20, 2024
75ad888
precision and refinement adjustments qme
thorek1 Oct 20, 2024
646254d
cover another doubling case for sylvester
thorek1 Oct 20, 2024
4dafdf1
handle sufficient init guess outside algos (qme, sylvester)
thorek1 Oct 20, 2024
b5a6401
fix wrong name in qme
thorek1 Oct 20, 2024
c2ece26
less allocs qme check
thorek1 Oct 20, 2024
f2ed0bb
tighter tol on sylvester
thorek1 Oct 20, 2024
1feba75
description of shocks
thorek1 Oct 20, 2024
60dc423
add shock_size to get irf
thorek1 Oct 20, 2024
180585a
add shcoks size to irf
thorek1 Oct 20, 2024
22e3709
lower tol on qme
thorek1 Oct 20, 2024
c84671a
if schur works we take it as true
thorek1 Oct 20, 2024
4682b7e
nkpc script
thorek1 Oct 20, 2024
cdad59e
forgot one irf call to include shock_size
thorek1 Oct 20, 2024
dfffb17
add nl analysis script
Oct 22, 2024
38c2046
turing compat 0.35
Oct 24, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 24 additions & 32 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,15 @@ jobs:
GKSwstype: "nul"
name: ${{ matrix.test_set }} - ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.version == 'nightly' || matrix.version == '^1.11.0-0' }}
continue-on-error: ${{ matrix.version == 'nightly' || matrix.version == '^1.12.0-0' }}
strategy:
fail-fast: false
matrix:
test_set: ["basic", "plots", "higher_order", "estimation"]
version: ['1.8', '1.9', '1.10']
version: ['1.11']
os: [ubuntu-latest, macos-latest, windows-latest]
arch: [x64, arm64]
exclude:
- version: '1.8'
os: ubuntu-latest
- version: '1.8'
os: windows-latest
- version: '1.9'
os: ubuntu-latest
- version: '1.9'
os: windows-latest
- arch: arm64
os: ubuntu-latest
- arch: arm64
Expand All @@ -35,48 +27,48 @@ jobs:
include:
- os: ubuntu-latest
prefix: xvfb-run
# - version: '1.10'
# - version: '1.11'
# os: macos-latest
# arch: x64
# test_set: "solver0"
# - version: '1.10'
# - version: '1.11'
# os: macos-latest
# arch: x64
# test_set: "solver1"
# - version: '1.10'
# - version: '1.11'
# os: macos-latest
# arch: x64
# test_set: "solver2"
# - version: '1.10'
# - version: '1.11'
# os: macos-latest
# arch: x64
# test_set: "solver3"
- version: '1.10'
os: macos-latest
arch: arm64
- version: '1.11'
os: macOS-latest
arch: x64
test_set: "estimate_sw07"
- version: '1.10'
os: macos-latest
arch: arm64
- version: '1.11'
os: macOS-latest
arch: x64
test_set: "1st_order_inversion_estimation"
- version: '1.10'
os: macos-latest
arch: arm64
- version: '1.11'
os: macOS-latest
arch: x64
test_set: "2nd_order_estimation"
- version: '1.10'
os: macos-latest
arch: arm64
- version: '1.11'
os: macOS-latest
arch: x64
test_set: "3rd_order_estimation"
# - version: '1.10'
# os: macOS-latest
# arch: x64
# test_set: "basic"
- version: '1.10.0'
os: macOS-latest
arch: x64
test_set: "basic"
- version: 'nightly'
os: ubuntu-latest
arch: x64
test_set: "basic"
allow_failure: true
- version: '^1.11.0-0'
- version: '^1.12.0-0'
os: macos-latest
arch: arm64
test_set: "basic"
Expand All @@ -94,7 +86,7 @@ jobs:
if: matrix.os != 'windows-latest'
run: echo "TEST_SET=${{ matrix.test_set }}" >> $GITHUB_ENV
- name: Set JULIA_NUM_THREADS for estimation tests
if: (matrix.version == '1.10' && (matrix.test_set == 'estimation' || matrix.test_set == 'estimate_sw07' || matrix.test_set == '1st_order_inversion_estimation' || matrix.test_set == '2nd_order_estimation' || matrix.test_set == '3rd_order_estimation'))
if: (matrix.version == '1.11' && (matrix.test_set == 'estimation' || matrix.test_set == 'estimate_sw07' || matrix.test_set == '1st_order_inversion_estimation' || matrix.test_set == '2nd_order_estimation' || matrix.test_set == '3rd_order_estimation'))
run: echo "JULIA_NUM_THREADS=auto" >> $GITHUB_ENV
- uses: actions/cache@v4
env:
Expand Down
16 changes: 8 additions & 8 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,16 @@ authors = ["Thore Kockerols <mail@thorekockerols.com>"]
version = "0.1.37"

[deps]
AbstractDifferentiation = "c29ec348-61ec-40c8-8164-b8c60e9d9f3d"
Accessors = "7d9f7c33-5ae7-4f3b-8dc6-eff91059b697"
AxisKeys = "94b1ba4f-4ee9-5380-92f1-94cde586c3c5"
BlockTriangularForm = "adeb47b7-70bf-415a-bb24-c358563e873a"
ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"
Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa"
DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
DifferentiationInterface = "a0c0ee7d-e4b9-4e03-894e-1c5f64a51d63"
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
DynarePreprocessor_jll = "23afba7c-24e5-5ee2-bc2c-b42e07f0492a"
ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210"
ImplicitDifferentiation = "57b37032-215b-411a-8a7c-41a003a55207"
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
Krylov = "ba0b0d4f-ebba-5204-a429-3ac8c609bfb7"
LaTeXStrings = "b964fa9f-0449-5b57-a5c2-d3ea65f4040f"
Expand Down Expand Up @@ -42,14 +41,14 @@ Suppressor = "fd094767-a336-5f1f-9728-57cf17d0bbfb"
SymPyPythonCall = "bc8888f7-b21e-4b7c-a06a-5d9c9496438c"
Symbolics = "0c5d862f-8b57-4792-8d23-62f2024744c7"
ThreadedSparseArrays = "59d54670-b8ac-4d81-ab7a-bb56233e17ab"
TimerOutputs = "a759f4b9-e2f1-59dc-863e-4aeb61b1ea8f"
Unicode = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5"

[weakdeps]
StatsPlots = "f3b207a7-027a-5e70-b257-86293d7955fd"
Turing = "fce5fe82-541a-59a6-adf8-730c64b5f9a0"

[compat]
AbstractDifferentiation = "0.5, 0.6"
Accessors = "0.1"
Aqua = "0.8"
AxisKeys = "0.2"
Expand All @@ -59,12 +58,12 @@ ChainRulesCore = "1"
Combinatorics = "1"
DataFrames = "1"
DataStructures = "0.18"
DifferentiationInterface = "0.6"
DocStringExtensions = "0.8, 0.9"
DynamicPPL = "0.23, 0.24, 0.25, 0.26, 0.27, 0.28"
DynamicPPL = "0.23, 0.24, 0.25, 0.26, 0.27, 0.28, 0.29, 0.30"
DynarePreprocessor_jll = "6"
FiniteDifferences = "0.12"
ForwardDiff = "0.10"
ImplicitDifferentiation = "0.5"
JET = "0.7, 0.8, 0.9"
JSON = "0.21"
Krylov = "0.9"
Expand All @@ -75,7 +74,7 @@ LinearOperators = "2"
MCMCChains = "6"
MacroTools = "0.5"
MatrixEquations = "2"
NLopt = "0.6, =1.0.1"
NLopt = "0.6, 1"
Optim = "1"
Pigeons = "0.3, 0.4"
Polyester = "0.7"
Expand All @@ -93,11 +92,12 @@ SpeedMapping = "0.3, 0.4"
StatsPlots = "0.15"
Subscripts = "0.1.3, 0.2"
Suppressor = "0.2"
SymPyPythonCall = "0.2, 0.3"
SymPyPythonCall = "0.2, 0.3, 0.4"
Symbolics = "5, 6"
Test = "1"
ThreadedSparseArrays = "0.2.3, 0.3"
Turing = "0.30, 0.31, 0.32, 0.33"
TimerOutputs = "0.5"
Turing = "0.30, 0.31, 0.32, 0.33, 0.34, 0.35"
Unicode = "1"
Zygote = "0.6"
julia = "1.8"
Expand Down
17 changes: 17 additions & 0 deletions docs/src/unfinished_docs/todo.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,26 @@
## High priority

- [ ] ss transition by entering new parameters at given periods
- [ ] allow to define y[ss] = 1 in parameters block
- [ ] check tols throughout. adopt max(abs,rel*norm) tols
- [ ] fix presample period for higher order estim
- [ ] newton SS solver once sol was found
- [ ] redo diffs (DiffInt or ForwardDiff or FastDiff)
- [ ] swtich from sympy to Symbolics
- [ ] optimize second order estim with SW07 or NAWM
- [ ] optimize third order with smaller model
- [ ] add argument to plotting functions to replace names in plots (e.g input a dictionnary: Dict(:dinve => "Investment growth"))
- [ ] programmatic model writing: accept {i}[0] as definition for variable
- [ ] fix higher order shock finder (3rd order) and check results for pruned second order. are the right state values taken for 1st and second order subprocesses?
- [ ] take analytical derivatives of NSSS funcs to reduce allocation and speed up the NSSS solver
- [ ] try a newton version of binder pesaran
- [ ] in the docs make it clear that for estimation you need to have variables which have the name of the observables in the dataframe and the parameters must be handed over to the get_loglikelihood function in the same order as declared. check with get_parameters
- [ ] check out dense sparse matmul on transposed matrices
- [ ] check out DiffInterface for NSSS solver
- [ ] write plotting callback for NSSS solver
- [ ] time NSSS solver and estimation codes
- [ ] move korn_s_s_s to higher order aux variables
- [ ] write own interior point solver
- [ ] append forecast (no shocks) after estimated variables
- [ ] write more tests for the plots
- [ ] add background part in docs on NSSS solver (use material from presentation)
Expand Down Expand Up @@ -103,6 +118,8 @@
- [ ] figure out combinations for inputs (parameters and variables in different formats for get_irf for example)
- [ ] weed out SS solver and saved objects

- [x] insight: spgemm in SparseArrays is the fastest way. threading doesnt work well due to memory/cache issues, csr format doesnt give many gains. other libraries dont improve over standard implementation (Finch...)
- [x] use kalman filter to initialize inversion filter for third order or some other simplification; didnt do it bcs it seems the inversion filter is well behaved for reasonable shock sizes
- [x] implement estimation tests for all models
- [x] make plotting options as dynamic setting instead of default, accept kwargs
- [x] streamline estimation part (dont do string matching... but rely on precomputed indices...)
Expand Down
14 changes: 7 additions & 7 deletions models/Smets_Wouters_2007.jl
Original file line number Diff line number Diff line change
Expand Up @@ -233,19 +233,19 @@ end

ctrend = 0.3982

z_ea = 0.4618
z_ea = 0.4618 # technology shock

z_eb = 1.8513
z_eb = 1.8513 # risk-premium shock

z_eg = 0.6090
z_eg = 0.6090 # government shock

z_em = 0.2397
z_em = 0.2397 # interest rate shock

z_ew = 0.2089
z_ew = 0.2089 # wage mark-up shock

z_eqs = 0.6017
z_eqs = 0.6017 # investment-specific shock

z_epinf = 0.1455
z_epinf = 0.1455 # price mark-up shock

1e-6 > ygap > -1e-6
end
Loading
Loading