Skip to content

Conversation

@FredericWantiez
Copy link
Member

Just moving the changes in #35 to match the last release.

@FredericWantiez
Copy link
Member Author

@yebai Had a look at the test in Turing for the new Libtask, seems like the breaking part is here:
https://github.com/TuringLang/Turing.jl/blob/60b7d3f2328904c4e0d88a974cc97eb752c2bb95/src/inference/AdvancedSMC.jl#L354
When DynamicPPL expands observe that creates a nested produce. Not too familiar with the way DynamicPPL works and how to patch it with

function (instr::Libtask.Instruction{}))
end

@yebai
Copy link
Member

yebai commented Dec 12, 2021

thanks @FredericWantiez, it looks like the same issue that we met in #35 . @KDr2 can you create a PR for Turing to address the issue?

@codecov
Copy link

codecov bot commented Dec 12, 2021

Codecov Report

Merging #36 (cefe010) into releases (350e2c1) will increase coverage by 0.42%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##           releases      #36      +/-   ##
============================================
+ Coverage     55.70%   56.13%   +0.42%     
============================================
  Files             5        5              
  Lines           368      367       -1     
============================================
+ Hits            205      206       +1     
+ Misses          163      161       -2     
Impacted Files Coverage Δ
src/container.jl 93.91% <100.00%> (+1.29%) ⬆️
src/model.jl 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 350e2c1...cefe010. Read the comment docs.

@yebai
Copy link
Member

yebai commented Dec 13, 2021

@KDr2 It seems some tests hang on Julia 1.3. Could you take a look, please?

@KDr2
Copy link
Member

KDr2 commented Dec 13, 2021

I am on it now. Seems that on Julia 1.3, we got one time more consuming than it is on 1.7:

v1.7:

("consumer -> start!", ttask.task) = ("consumer -> start!", Task (runnable) @0x00007fbda79f1cd0)
("consumer -> take!", ttask.task) = ("consumer -> take!", Task (runnable) @0x00007fbda79f1cd0)
("producer -> put!", current_task()) = ("producer -> put!", Task (runnable) @0x00007fbda79f1cd0)
("producer -> take!", current_task()) = ("producer -> take!", Task (runnable) @0x00007fbda79f1cd0)
("consumer -> put!", ttask.task) = ("consumer -> put!", Task (runnable) @0x00007fbda79f1cd0)
("producer -> put!", current_task()) = ("producer -> put!", Task (runnable) @0x00007fbda79f1cd0)
("consumer -> take!", ttask.task) = ("consumer -> take!", Task (runnable) @0x00007fbda79f1cd0)
("producer -> take!", current_task()) = ("producer -> take!", Task (runnable) @0x00007fbda79f1cd0)

v1.3:

("consumer -> start!", ttask.task) = ("consumer -> start!", Task (runnable) @0x00007f47b7004010)
("consumer -> take!", ttask.task) = ("consumer -> take!", Task (runnable) @0x00007f47b7004010)
("producer -> put!", current_task()) = ("producer -> put!", Task (runnable) @0x00007f47b7004010)
("producer -> take!", current_task()) = ("producer -> take!", Task (runnable) @0x00007f47b7004010)
("consumer -> put!", ttask.task) = ("consumer -> put!", Task (runnable) @0x00007f47b7004010)
("producer -> put!", current_task()) = ("producer -> put!", Task (runnable) @0x00007f47b7004010)
("consumer -> take!", ttask.task) = ("consumer -> take!", Task (runnable) @0x00007f47b7004010)
("producer -> take!", current_task()) = ("producer -> take!", Task (runnable) @0x00007f47b7004010)
("consumer -> put!", ttask.task) = ("consumer -> put!", Task (runnable) @0x00007f47b7004010)
("consumer -> take!", ttask.task) = ("consumer -> take!", Task (runnable) @0x00007f47b7004010)

@KDr2
Copy link
Member

KDr2 commented Dec 14, 2021

@yebai Had a look at the test in Turing for the new Libtask, seems like the breaking part is here: https://github.com/TuringLang/Turing.jl/blob/60b7d3f2328904c4e0d88a974cc97eb752c2bb95/src/inference/AdvancedSMC.jl#L354 When DynamicPPL expands observe that creates a nested produce. Not too familiar with the way DynamicPPL works and how to patch it with

function (instr::Libtask.Instruction{}))
end

I ran test cases of Turing, and all of them have passed. Had some awesome guys already fixed them?
Here are the packages I used:

(Turing) pkg> status
Project Turing v0.19.1
    Status `~/Work/julia/Turing.jl/Project.toml`
  [80f14c24] AbstractMCMC v3.2.1
  [0bf59076] AdvancedHMC v0.3.2
  [5b7e9947] AdvancedMH v0.6.6
  [576499cb] AdvancedPS v0.2.4
  [b5ca4192] AdvancedVI v0.1.3
  [198e06fe] BangBang v0.3.32
  [76274a88] Bijectors v0.9.11
  [864edb3b] DataStructures v0.18.11
  [31c24e10] Distributions v0.25.36
  [ced4e74d] DistributionsAD v0.6.34
  [ffbed154] DocStringExtensions v0.8.6
  [366bfd00] DynamicPPL v0.16.2
  [cad2338a] EllipticalSliceSampling v0.4.4
  [f6369f11] ForwardDiff v0.10.24
  [6f1fad26] Libtask v0.5.3 [`../Libtask.jl`]
  [c7f686f2] MCMCChains v5.0.1
  [86f7a689] NamedArrays v0.9.6
  [189a3867] Reexport v1.2.2
  [ae029012] Requires v1.1.3
  [0bca4576] SciMLBase v1.13.6
  [276daf66] SpecialFunctions v1.8.1
  [2913bbd2] StatsBase v0.33.13
  [4c63d2b9] StatsFuns v0.9.14
  [9f7883ad] Tracker v0.2.16
  [700de1a5] ZygoteRules v0.2.2
  [37e2e46d] LinearAlgebra
  [de0858da] Printf
  [9a3f8284] Random
  [10745b16] Statistics

@KDr2
Copy link
Member

KDr2 commented Dec 14, 2021

@KDr2 It seems some tests hang on Julia 1.3. Could you take a look, please?

I think this commit TuringLang/Libtask.jl@0334a49 would fix it.

@yebai yebai merged commit 488822c into releases Dec 14, 2021
@delete-merged-branch delete-merged-branch bot deleted the feature/release branch December 14, 2021 08:57
@KDr2 KDr2 mentioned this pull request Dec 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants