You are viewing an old version of this page. View the current version.
Compare with Current
View Page History
Version 1
Next »
Fri 3/10/2017 2:23 PM cpo:
Can you email us Kartik’s powder-pattern plot so Mikhail can try to match it?
Fri 3/10/2017 3:28 PM mliang:
The files are in /reg/neh/home4/mliang/analysis/rel-cxif5315/work1/kartik
Here is the code I got from David to open things:
C++
string imageFile = "XXXX.bin";
double *imageData;
FILE *fp;
int area = 1701*1701;
imageData = (double*)malloc(area * sizeof(double));
fp = fopen(imageFile.c_str(), "rb");
int ret = fread(imageData, sizeof(double), area, fp);
fprintf(stderr, "fread %s returned %d entries\n", imageFile.c_str(), ret);
MATLAB
imfileID = fopen(XXXX.bin');
im = fread(imfileID,[1701 1701],'double’);