ARG CPU_OR_GPU ARG AWS_REGION FROM 520713654638.dkr.ecr.${AWS_REGION}.amazonaws.com/sagemaker-rl-mxnet:coach0.11.0-${CPU_OR_GPU}-py3 RUN pip install -U pip ############################################ # EnergyPlus ############################################ # Install EnergyPlus. Instructions borrowed from: https://github.com/NREL/docker-energyplus # This is not ideal. The tarballs are not named nicely and EnergyPlus versioning is strange ENV ENERGYPLUS_VERSION 8.8.0 ENV ENERGYPLUS_TAG v8.8.0 ENV ENERGYPLUS_SHA 7c3bbe4830 # This should be x.y.z, but EnergyPlus convention is x-y-z ENV ENERGYPLUS_INSTALL_VERSION 8-8-0 # Downloading from Github # e.g. https://github.com/NREL/EnergyPlus/releases/download/v8.3.0/EnergyPlus-8.3.0-6d97d074ea-Linux-x86_64.sh ENV ENERGYPLUS_DOWNLOAD_BASE_URL https://github.com/NREL/EnergyPlus/releases/download/$ENERGYPLUS_TAG ENV ENERGYPLUS_DOWNLOAD_FILENAME EnergyPlus-$ENERGYPLUS_VERSION-$ENERGYPLUS_SHA-Linux-x86_64.sh ENV ENERGYPLUS_DOWNLOAD_URL $ENERGYPLUS_DOWNLOAD_BASE_URL/$ENERGYPLUS_DOWNLOAD_FILENAME # Install java RUN apt-get update && apt-get install -y openjdk-8-jdk openjdk-8-jre # Collapse the update of packages, download and installation into one command # to make the container smaller & remove a bunch of the auxiliary apps/files # that are not needed in the container RUN apt-get update && apt-get install -y ca-certificates curl \ && curl -SLO $ENERGYPLUS_DOWNLOAD_URL \ && chmod +x $ENERGYPLUS_DOWNLOAD_FILENAME \ && echo "y\r" | ./$ENERGYPLUS_DOWNLOAD_FILENAME \ && rm $ENERGYPLUS_DOWNLOAD_FILENAME \ && cd /usr/local/EnergyPlus-$ENERGYPLUS_INSTALL_VERSION \ PostProcess/EP-Compare PreProcess/FMUParser PreProcess/ParametricPreProcessor PreProcess/IDFVersionUpdater WORKDIR /opt/ml # Tell sagemaker-containers where the launch point is for training job. ENV SAGEMAKER_TRAINING_COMMAND /opt/ml/code/sagemaker-train.sh