Datasets may be confidential; sample names and measured unit cells committed to the repo can leak outside the group working on them. Scrub existing occurrences and add a "No sample identities in the repository" section to CLAUDE.md (forbidden: sample/dataset names, internal codes, measured cells tied to a sample; fine: space group / lattice / twinning descriptors). - Comments: replace internal dataset codes and protein names with the crystallographic situation they illustrate (centred vs pseudo-symmetric, holohedral, cubic, F-cubic/hexagonal, ...). - Docs: same, in the analysis/writer/stream references and example configs. - Tests: rename sample-named identifiers, TEST_CASE names, file prefixes and asserted labels to neutral crystallographic names (e.g. tetragonal_uc); behaviour unchanged. Reduce the CrystFEL reference PDB to a bare CRYST1 cell file (cell.pdb) and rename the reference data file. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
32 lines
1.2 KiB
Python
32 lines
1.2 KiB
Python
import requests
|
|
import h5py
|
|
import hdf5plugin
|
|
|
|
requests.post("http://localhost:5232/initialize")
|
|
|
|
with h5py.File("compression_benchmark.h5", "r") as f:
|
|
img = f["/entry/data/data"]
|
|
res = requests.put(url="http://localhost:5232/config/internal_generator_image?id=0", data = img[0, :, :].tobytes())
|
|
res = requests.put(url="http://localhost:5232/config/internal_generator_image?id=1", data = img[1, :, :].tobytes())
|
|
res = requests.put(url="http://localhost:5232/config/internal_generator_image?id=2", data = img[2, :, :].tobytes())
|
|
res = requests.put(url="http://localhost:5232/config/internal_generator_image?id=3", data = img[3, :, :].tobytes())
|
|
res = requests.put(url="http://localhost:5232/config/internal_generator_image?id=4", data = img[4, :, :].tobytes())
|
|
|
|
start_input = {
|
|
"beam_x_pxl":1090,
|
|
"beam_y_pxl":1136,
|
|
"detector_distance_mm":75,
|
|
"incident_energy_keV":12.4,
|
|
"sample_name":"test_sample",
|
|
"unit_cell":{"a":36.9, "b":78.95, "c":78.95, "alpha":90, "beta":90, "gamma":90},
|
|
"images_per_trigger":18,
|
|
"file_prefix":"test_grid",
|
|
"grid_scan": {
|
|
"n_fast":3,
|
|
"step_x_um": 5.0,
|
|
"step_y_um": -3.0,
|
|
"snake": True
|
|
}
|
|
}
|
|
requests.post("http://localhost:5232/start", json=start_input)
|