georkara / Chargym-Charging-Station

Chargym simulates the operation of an electric vehicle charging station (EVCS) considering random EV arrivals and departures within a day. This is a generalised environment for charging/discharging EVs under various disturbances (weather conditions, pricing models, stochastic arrival-departure EV times and stochastic Battery State of Charge (BOC) at arrival). This is an open source OpenAI Gym environment for the implementation of Reinforcement Learning (RL), Rule-based approaches (RB) and Intelligent Control (IC).
103 stars 24 forks source link

Question about installation #8

Open RichieZou opened 3 days ago

RichieZou commented 3 days ago

Thank you for sharing so powerful project.

When I follow your instruction on installing this project, there are some errors when I conduct "pip install -e .".

Therefore, I change the contain in setup.py into (By the way, the python version must be 3.7, and there is error for gym==0.19.0 when I tried python 3.8):

from setuptools import setup setup(name='Chargym_Charging_Station', version='0.0.1', packages=['Solvers', 'Chargym_Charging_Station'],
install_requires=[ 'absl-py==1.0.0', 'astunparse==1.6.3', 'atari-py==0.2.6', 'cached-property==1.5.2', 'cachetools==5.0.0', 'certifi==2021.10.8', 'charset-normalizer==2.0.12', 'cloudpickle==1.6.0', 'cycler==0.11.0', 'flatbuffers==2.0', 'fonttools==4.29.1', 'gast==0.5.3', 'google-auth==2.6.0', 'google-auth-oauthlib==0.4.6', 'google-pasta==0.2.0', 'grpcio==1.43.0', 'gym==0.19.0', 'h5py==3.6.0', 'idna==3.3', 'importlib-metadata==4.11.0', 'keras==2.8.0', 'Keras-Preprocessing==1.1.2', 'kiwisolver==1.3.2', 'libclang==13.0.0', 'Markdown==3.3.6', 'matplotlib==3.5.1', 'mpmath==1.2.1', 'numpy==1.21.5', 'oauthlib==3.2.0', 'opencv-python==4.5.5.62', 'opt-einsum==3.3.0', 'packaging==21.3', 'pandas==1.3.5', 'Pillow==9.0.1', 'protobuf==3.19.4', 'psutil==5.9.0', 'pyasn1==0.4.8', 'pyasn1-modules==0.2.8', 'pyparsing==3.0.7', 'python-dateutil==2.8.2', 'pytz==2021.3', 'requests==2.27.1', 'requests-oauthlib==1.3.1', 'rsa==4.8', 'scipy==1.7.3', 'six==1.16.0', 'stable-baselines3==1.4.0', 'sympy==1.9', 'tensorboard==2.8.0', 'tensorboard-data-server==0.6.1', 'tensorboard-plugin-wit==1.8.1', 'tensorflow==2.8.0', 'tensorflow-io-gcs-filesystem==0.24.0', 'termcolor==1.1.0', 'tf-estimator-nightly==2.8.0.dev2021122109', 'torch==1.10.2', 'typing_extensions==4.1.1', 'urllib3==1.26.8', 'Werkzeug==2.0.3', 'wrapt==1.13.3', 'zipp==3.7.0' ] )

georkara commented 3 days ago

Hi RichieZou, Thank you for your interest in Chargym and for reporting this issue, since it can assist others who may encounter similar issues in the future. I want to assure you that I have the best intentions to help you resolve this issue, but I cannot guarantee that my proposed solution will fully address the problem. I hope it wil bring us closer to a resolution.

I think that the project requires Python 3.7 and in that case you will not have an issue with the gym==0.19.0. Once you create a virtual environment with Python 3.7, install the dependencies "pip install -r requirements.txt" and then "pip install -e ." If it is critical for you to use Python 3.8 maybe a newer gym version like gym==0.21.0 or gym==0.23.0 would be ok.

In case you resolve this, I would deeply appreciate to write the way that it was solved to help others that may have similar issue in thefuture. Thanks. Giorgos

RichieZou commented 3 days ago

Thank you for your help. Another bug that I find when I run DDPG_training.py on linux system is related to path: in Charging_Station_Environment.py line 51:
self.current_folder = os.path.realpath(os.path.join(os.path.dirname(file), '..')) + '\Files\' change it to self.current_folder = os.path.realpath(os.path.join(os.path.dirname(file), '..')) + '/Files/'

Just remind those linux users :->