Closed zhujun98 closed 6 years ago
LGTM
Would it be better to have a more realistic simulation of multiple sources, e.g. 16 detector modules, rather than duplicating the combined output of a full detector?
Also, if we stick with this approach, I'd like a name like nsources
rather than just ns
.
I agree it would be nice to have a "real" simulation of multiple sources in the future. But the point is, now we need something to test the client's ability to parse a multi-source data, and it does not matter whether they have the same content or not. Thomas and I tested the cpp client on the online cluster yesterday with real data, and it works very well. At least, this means that the data content generated by the current simulator is good enough to mimic the real data.
To generate multi-source data, use start_gen(port, ns=2). The source names will be the default source name appended by "-1", "-2", e.g. "SPB_DET_AGIPD1M-1/DET/detector-1", "SPB_DET_AGIPD1M-1/DET/detector-2".
The default start_gen(port) behaves the same as before.