imtoolkit.DifferentialMLDSimulator module¶
- 
class imtoolkit.DifferentialMLDSimulator.DifferentialMLDSimulator(codes, channel)[source]¶
- Bases: - imtoolkit.Simulator.Simulator- A simulator that relies on the non-coherent maximum likelihood detector, that does not require precise estimates of channel state information at the receiver. The environment variable USECUPY determines whether to use cupy or not. - Parameters
- codes (ndarray) – an input codebook, which is generated on the CPU memory and is transferred into the GPU memory. 
- channel (imtoolkit.Channel) – a channel model used in simulation. 
 
 - 
simulateBERParallel(params, outputFile=True, printValue=True)[source]¶
- Simulates BER values at multiple SNRs, where the massively parallel algorithm is used. This implementation is especially designed for cupy. - Parameters
- params (imtoolkit.Parameter) – simulation parameters. 
- outputFile (bool) – a flag that determines whether to output the obtained results to the results/ directory. 
- printValue (bool) – a flag that determines whether to print the simulated values. 
 
- Returns
- a dict that has two keys: snr_dB and ber, and contains the corresponding results. All the results are transferred into the CPU memory. 
- Return type
- dict 
 
 - 
simulateBERReference(params, outputFile=True, printValue=True)[source]¶
- Simulates BER values at multiple SNRs, where the straightforward reference algorithm is used. Note that this time complexity is unrealistically high. - Parameters
- params (imtoolkit.Parameter) – simulation parameters. 
- outputFile (bool) – a flag that determines whether to output the obtained results to the results/ directory. 
- printValue (bool) – a flag that determines whether to print the simulated values. 
 
- Returns
- a dict that has two keys: snr_dB and ber, and contains the corresponding results. All the results are transferred into the CPU memory. 
- Return type
- dict 
 
 
