Comments (3)
It looks like we are calling a removed function @KDr2 - could you take a look, please?
from libtask.jl.
Looks like it's a CodeInfoTools
error when running tests with coverage=true
. @KDr2 you found the issue earlier here I think issue
This task
function (m::Model)(rng)
m.a = rand(rng, Normal())
AdvancedPS.observe(Normal(), m.a)
m.b = rand(rng, Normal())
return AdvancedPS.observe(Normal(), m.b)
end
produces the right type annotations when running using Pkg; Pkg.test()
:
CodeInfo(
@ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:163 within `Model`
1 ─ %1 = Main.Normal()::Core.Const(Normal{Float64}(μ=0.0, σ=1.0))
│ %2 = Main.rand(rng, %1)::Float64
│ Base.setproperty!(m, :a, %2)::Any
│ @ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:164 within `Model`
│ %4 = AdvancedPS.observe::Core.Const(AdvancedPS.observe)
│ %5 = Main.Normal()::Core.Const(Normal{Float64}(μ=0.0, σ=1.0))
│ %6 = Base.getproperty(m, :a)::Float64
│ (%4)(%5, %6)::Any
│ @ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:166 within `Model`
│ %8 = Main.Normal()::Core.Const(Normal{Float64}(μ=0.0, σ=1.0))
│ %9 = Main.rand(rng, %8)::Float64
│ Base.setproperty!(m, :b, %9)::Any
│ @ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:167 within `Model`
│ %11 = AdvancedPS.observe::Core.Const(AdvancedPS.observe)
│ %12 = Main.Normal()::Core.Const(Normal{Float64}(μ=0.0, σ=1.0))
│ %13 = Base.getproperty(m, :b)::Float64
│ %14 = (%11)(%12, %13)::Core.Const(nothing)
└── return %14
)
but not when running using Pkg; Pkg.test(; coverage=true)
which is what is setup in CI:
CodeInfo(
@ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:163 within `Model`
1 ─ %1 = Main.Normal()::Nothing <---- extra Nothing, should be the ::Core.Const(Normal{Float64}(μ=0.0, σ=1.0)) below
│ %2 = Main.rand(rng, %1)::Core.Const(Normal{Float64}(μ=0.0, σ=1.0)) <---- Should be ::Float64
│ Base.setproperty!(m, :a, %2)::Float64
│ %4 = AdvancedPS.observe::Any
│ @ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:164 within `Model`
│ %5 = Main.Normal()::Nothing
│ %6 = Base.getproperty(m, :a)::Core.Const(AdvancedPS.observe)
│ (%4)(%5, %6)::Core.Const(Normal{Float64}(μ=0.0, σ=1.0))
│ %8 = Main.Normal()::Float64
│ %9 = Main.rand(rng, %8)::Any
│ @ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:166 within `Model`
│ Base.setproperty!(m, :b, %9)::Nothing
│ %11 = AdvancedPS.observe::Core.Const(Normal{Float64}(μ=0.0, σ=1.0))
│ %12 = Main.Normal()::Float64
│ %13 = Base.getproperty(m, :b)::Any
│ @ /home/frederic/Documents/projects/turing/AdvancedPS.jl/test/smc.jl:167 within `Model`
│ %14 = (%11)(%12, %13)::Nothing
└── return %14
)
from libtask.jl.
I'm curious why is this not triggered before...
from libtask.jl.
Related Issues (20)
- `Fusing` instructions on tape between `produce` statements HOT 1
- Depreciate `Libtask.consume` in favour of `Base.iterate`? HOT 2
- Replace `IRTools` with `CodeInfoTools` HOT 3
- Remove the TArray related docs HOT 6
- Remove the dependency on `MacroTools`
- Lazy copy of entries in `TapedFunction.bindings::Dict` HOT 2
- Add standalone benchmarks for `TapedFunction`
- The performance issue HOT 10
- Mention `tape_copy` in doc or expose a deepcopy flag ?
- Issue with copy and new `TapedTask` HOT 3
- Copy args HOT 10
- Widen Julia compat entry for 1.6 HOT 2
- Unused `arg` in `TapedTask`
- Improve `TapedTask` constructor
- Cache key in tapedfunction HOT 2
- `TypeError` in `tape_copy` for newer versions of Julia HOT 1
- Support for multiple nested `produce` HOT 1
- Redundant Code? HOT 1
- Cannot Precompile `Libtask.jl` on Julia Nightly (1.12.0-DEV.81) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from libtask.jl.