first version of model runner and model feedback (#70)

* Implemented model.py

- Need to run within the RDAgent folder (relevant path)
- Each time copy a template & insert code & run qlib & store result back to experiment

* Create model.py

* Create conf.yaml

This is the sample conf.yaml to be copied each time.

This has gone several times of iteration and is now working for both tabular and Time-Series data.

* Create read_exp.py

This is to read the results within Qlib

* Create ReadMe.md

* Update model.py

* Create test_model.py

A testing file that separates model code generation and running&feedback section.

* move the template folder

* help xisen finish the model runner

* help xisen fix improve model feedback generation

* delete debug file

* rename readme.md

---------

Co-authored-by: Xisen Wang <118058822+Xisen-Wang@users.noreply.github.com>
This commit is contained in:
Xu Yang
2024-07-16 10:33:53 +08:00
committed by GitHub
parent 947e52bacd
commit be2c19307e
19 changed files with 369 additions and 154 deletions
+3
View File
@@ -122,6 +122,7 @@ class DockerConf(BaseSettings):
# And the extra data may be shared and the downloading can be time consuming.
# So we just want to download it once.
network: str | None = "bridge" # the network mode for the docker
shm_size: str | None = None
class QlibDockerConf(DockerConf):
@@ -131,6 +132,7 @@ class QlibDockerConf(DockerConf):
mount_path: str = "/workspace/qlib_workspace/"
default_entry: str = "qrun conf.yaml"
extra_volumes: dict = {Path("~/.qlib/").expanduser().resolve(): "/root/.qlib/"}
shm_size: str | None = "16g"
class DockerEnv(Env[DockerConf]):
@@ -180,6 +182,7 @@ class DockerEnv(Env[DockerConf]):
working_dir=self.conf.mount_path,
# auto_remove=True, # remove too fast might cause the logs not to be get
network=self.conf.network,
shm_size=self.conf.shm_size,
)
logs = container.logs(stream=True)
for log in logs: