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

MultiDatasetTradingEnv incompatibility with gymnasium==1.0.0 and issues in selection of multi-dataset #28

Open
sachetz opened this issue Dec 12, 2024 · 0 comments

Comments

@sachetz
Copy link

sachetz commented Dec 12, 2024

I came across 2 issues in the MultiDatasetTradingEnv class:

  1. gymnasium==1.0.0 requires the env.reset() function to take 2 parameters, seed and options. The class currently only has seed, and this causes an error:
    TypeError: reset() got an unexpected keyword argument 'options'

  2. The selection of the dataset in the multi-dataset process seems to be broken. Instead of selecting the least used dataset, it ends up selecting the first one every time.

potential_dataset_pathes = np.where(self.dataset_nb_uses == self.dataset_nb_uses.min())[0]
random_int = np.random.randint(potential_dataset_pathes.size)
dataset_path = self.dataset_pathes[random_int]

For example, if there is only one dataset that has the minimum uses, random_int always ends up being 0, and so only the first dataset is always selected - regardless of the actual usage.

sachetz added a commit to sachetz/Gym-Trading-Env that referenced this issue Dec 12, 2024
…ility with gymnasium==1.0.0 and issues in selection of multi-dataset
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