Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

64 bit numbers are implicitly converted to 32 bit #117

Open
Kakadus opened this issue Jun 4, 2024 · 0 comments
Open

64 bit numbers are implicitly converted to 32 bit #117

Kakadus opened this issue Jun 4, 2024 · 0 comments

Comments

@Kakadus
Copy link
Contributor

Kakadus commented Jun 4, 2024

Hi,
I wanted to use OpenGymBoxContainer<uint64_t> but the numbers were converted to 32 bit after loading the box from its protobuf message. 64bit wide numbers are handled in the corresponding python code:

else if (name == "uint8_t" || name == "uint16_t" || name == "uint32_t" || name == "uint64_t")
    {
        m_dtype = ns3_ai_gym::UINT;
    }

and c++ code

else if (name == "uint8_t" || name == "uint16_t" || name == "uint32_t" || name == "uint64_t")
    {
        m_dtype = ns3_ai_gym::UINT;
    }

but the protobuf messages only have 32bit wide integers. This does not work....

message BoxDataContainer {
	Dtype dtype = 1;
	repeated uint32 shape = 2;

	repeated int32 intData = 3;
	repeated uint32 uintData = 4;
	repeated float floatData = 5;
	repeated double doubleData = 6;
}

This is the same case with DiscreteContainer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant