Comments (2)
Parameters solved:
A nested NamedTuple and the @extract
macro from ExtractMacro.jl:
julia> using ExtractMacro
julia> plane_par = (α=10, ϵ=0.1, other_par = 11.3)
(α = 10, ϵ = 0.1, other_par = 11.3)
julia> sphere_par = (α=5, ϵ=0.05, )
(α = 5, ϵ = 0.05)
julia> iter_par1 = (maxit=100, p = 0.99)
(maxit = 100, p = 0.99)
julia> new_shape = (α=1, ϵ=15, oth="A")
(α = 1, ϵ = 15, oth = "A")
julia> ransacpars = (plane=plane_par, sphere=sphere_par, iterations=iter_par1)
(plane = (α = 10, ϵ = 0.1, other_par = 11.3), sphere = (α = 5, ϵ = 0.05), iterations = (maxit = 100, p = 0.99))
julia> function test1(p)
@extract p : sphere_p=sphere plane_p=plane
@show sphere_p
@show plane_p
end
test1 (generic function with 1 method)
julia> test1(ransacpars)
sphere_p = (α = 5, ϵ = 0.05)
plane_p = (α = 10, ϵ = 0.1, other_par = 11.3)
(α = 10, ϵ = 0.1, other_par = 11.3)
julia> test1(ransacpars);
sphere_p = (α = 5, ϵ = 0.05)
plane_p = (α = 10, ϵ = 0.1, other_par = 11.3)
julia> function test2(p)
@extract p : sphere_p=sphere plane_p=plane
@show sphere_p
@show plane_p
end
test2 (generic function with 1 method)
julia> function test2(p)
@extract p : sphere_p=sphere plane_p=plane
@show sphere_p
@extract sphere_p : sphere_alpha=α
@extract plane_p : plane_alpha = α
@show sphere_alpha
@show plane_alpha
end
test2 (generic function with 1 method)
julia> test2(ransacpars);
sphere_p = (α = 5, ϵ = 0.05)
sphere_alpha = 5
plane_alpha = 10
julia> newshape_par = (newshape=new_shape)
(α = 1, ϵ = 15, oth = "A")
julia> newshape_par = (newshape=new_shape,)
(newshape = (α = 1, ϵ = 15, oth = "A"),)
julia> merge(ransacpars, newshape_par)
(plane = (α = 10, ϵ = 0.1, other_par = 11.3), sphere = (α = 5, ϵ = 0.05), iterations = (maxit = 100, p = 0.99), newshape = (α = 1, ϵ = 15, oth = "A"))
from ransac.jl.
Implemented in #12
from ransac.jl.
Related Issues (20)
- Add back sampling and examples for functional validation
- Add more views() HOT 1
- Estimatescore
- The `isntequal()` function is not working 100% as I want
- Octree and point cloud should be merged in one type HOT 1
- Struct-of-arrays vs array-of-structs HOT 1
- Overall better sampling HOT 2
- Performance meta HOT 2
- CI takes too long for PR-s
- Set float types HOT 2
- Another RANSAC implementation in Julia HOT 1
- Failure due to negative sqrt HOT 1
- Use ProgressMeter.jl instead of logging
- CI rewrite
- Consider using StructArrays.jl
- Default values like in CGAL
- Use of ConstructiveGeometry.jl
- Rework logging system
- change reset_rand keyword to Union{Nothing, Int}
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 ransac.jl.