aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--julia/CrystFEL/src/CrystFEL.jl4
-rw-r--r--julia/CrystFEL/src/indexing.jl11
-rw-r--r--julia/alignment-test-moved.geom2
-rw-r--r--julia/alignment-test.geom2
-rw-r--r--julia/alignment-test.jl7
5 files changed, 21 insertions, 5 deletions
diff --git a/julia/CrystFEL/src/CrystFEL.jl b/julia/CrystFEL/src/CrystFEL.jl
index 17ad2677..017bd530 100644
--- a/julia/CrystFEL/src/CrystFEL.jl
+++ b/julia/CrystFEL/src/CrystFEL.jl
@@ -64,4 +64,8 @@ include("streams.jl")
using .Streams
export Stream
+include("millepede.jl")
+using .Millepede
+export Mille
+
end # of module
diff --git a/julia/CrystFEL/src/indexing.jl b/julia/CrystFEL/src/indexing.jl
index 60e293d9..7dabd15c 100644
--- a/julia/CrystFEL/src/indexing.jl
+++ b/julia/CrystFEL/src/indexing.jl
@@ -113,12 +113,19 @@ function Indexer(methods, dtempl, cell; tolerances=(0.05,0.05,0.05,1.5,1.5,1.5),
end
-function index(image::Image, idxr::Indexer)
+function index(image::Image, idxr::Indexer; mille=nothing)
+
+ if mille === nothing
+ imille = C_NULL
+ else
+ imille = mille.internalptr
+ end
+
@ccall libcrystfel.index_pattern_4(image.internalptr::Ptr{InternalImage},
idxr.indexingpriv::Ptr{IndexingPriv},
C_NULL::Ptr{Cvoid},
C_NULL::Ptr{Cvoid},
- C_NULL::Ptr{Cvoid})::Cvoid
+ imille::Ptr{Cvoid})::Cvoid
end
diff --git a/julia/alignment-test-moved.geom b/julia/alignment-test-moved.geom
index c1943056..c834973b 100644
--- a/julia/alignment-test-moved.geom
+++ b/julia/alignment-test-moved.geom
@@ -47,3 +47,5 @@ q3/fs = x
q3/ss = y
q3/corner_x = -1054
q3/corner_y = -1054
+
+group_all = q0,q1,q2,q3
diff --git a/julia/alignment-test.geom b/julia/alignment-test.geom
index 11668fca..b2be83c6 100644
--- a/julia/alignment-test.geom
+++ b/julia/alignment-test.geom
@@ -47,3 +47,5 @@ q3/fs = x
q3/ss = y
q3/corner_x = -1054
q3/corner_y = -1054
+
+group_all = q0,q1,q2,q3
diff --git a/julia/alignment-test.jl b/julia/alignment-test.jl
index 6fec3256..3948c6fb 100644
--- a/julia/alignment-test.jl
+++ b/julia/alignment-test.jl
@@ -16,7 +16,7 @@ function sketch_pattern(image, cr)
end
-function simulate_and_index(cell, image_true, dtempl_moved, n)
+function simulate_and_index(cell, image_true, dtempl_moved, mille, n)
indexer = Indexer("asdf", dtempl_moved, cell, retry=false, multilattice=false, refine=true)
@@ -27,7 +27,7 @@ function simulate_and_index(cell, image_true, dtempl_moved, n)
image_moved = Image(dtempl_moved)
image_moved.peaklist = peaklist
- index(image_moved, indexer)
+ index(image_moved, indexer, mille=mille)
end
end
@@ -37,4 +37,5 @@ dtempl_true = loaddatatemplate("julia/alignment-test.geom")
image_true = Image(dtempl_true)
cell = UnitCell(MonoclinicLattice, PrimitiveCell, 123, 45, 80, 90, 97, 90)
dtempl_moved = loaddatatemplate("julia/alignment-test-moved.geom")
-simulate_and_index(cell, image_true, dtempl_moved, 100)
+mille = Mille("mille.dat")
+simulate_and_index(cell, image_true, dtempl_moved, mille, 100)