-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from ebalaban/fix-package
Cleaned up LightDarkLPDM.
- Loading branch information
Showing
24 changed files
with
38 additions
and
119 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
*.jl.cov | ||
*.jl.*.cov | ||
*.jl.mem | ||
*.DS_Store | ||
*.DS_Store | ||
Manifest.toml | ||
results* |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
name = "LightDarkLPDM" | ||
uuid = "61eceab4-c7ab-4531-afd3-78042c72ca60" | ||
version = "0.1.0" | ||
|
||
[deps] | ||
Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa" | ||
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f" | ||
LPDM = "afad1059-261e-5166-a24b-444a49bdbc07" | ||
POMDPs = "a93abf59-7444-517b-a68a-c42f96afdd7d" | ||
Parameters = "d96e819e-fc66-5662-9728-84c9c7592b0a" | ||
Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7" | ||
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" | ||
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,46 +1,9 @@ | ||
using LightDarkPOMDPs | ||
using LightDarkLPDM | ||
using Base.Test | ||
using POMDPs | ||
using POMDPToolbox | ||
using StaticArrays | ||
using Plots | ||
using ParticleFilters | ||
|
||
#### LightDark2D Problem #### | ||
|
||
p = LightDark2D() | ||
|
||
# simulate with a policy that moves -0.01 times the observation | ||
hr = HistoryRecorder(max_steps=10) | ||
h = sim(p, simulator=hr) do o | ||
@show o | ||
return -0.01*o | ||
end | ||
@show p.count | ||
|
||
|
||
# simulate with a kalman filter | ||
bpol = FunctionPolicy(b -> -0.5*mean(b)) | ||
up = LightDark2DKalman(p) | ||
h = simulate(hr, p, bpol, up) | ||
|
||
# plotly() | ||
pl = plot(p); | ||
plot!(pl, h) | ||
# gui() | ||
|
||
#### LightDark2DTarget Problem #### | ||
|
||
p = LightDark2DTarget() | ||
|
||
pl = plot(p); | ||
up = SIRParticleFilter(p, 1000) | ||
b = initialize_belief(up, initial_state_distribution(p)) | ||
plot!(pl, b) | ||
gui() | ||
|
||
hist = simulate(hr, p, bpol, up) | ||
println("state trajectory") | ||
for s in state_hist(hist) | ||
@show s | ||
end | ||
#Removed test code from here since it was for LightDarkPOMDPs. |