Skip to content

default_dtype in MPPrioritizedReplayBuffer seems no use with float16

I update cpprb to 9.4.3, and replace the old prioritizedReplayBuffer to MPprioritizedReplayBuffer like tutorial, but some problem occured. Everything works fine using prioritizedReplayBuffer .

Before:

global_rb = manager.PrioritizedReplayBuffer(memory_size, env_dict=env_dict, alpha=PER_a, default_dtype=np.float16, check_for_update=True)

After:

global_rb = MPPrioritizedReplayBuffer(memory_size, env_dict=env_dict, alpha=PER_a, default_dtype=np.float16)

When running the code, this error occurs:

NotImplementedError: Converting dtype('float16') to a ctypes type

The numpy version is 1.19.3.

Edited by ao xue