Spaces:
Build error
Build error
Update Space
Browse files- Dockerfile +16 -0
- Makefile +4 -0
- Readme.md +22 -0
- pyproject.toml +36 -0
Dockerfile
ADDED
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
FROM node:20.10.0
|
2 |
+
|
3 |
+
WORKDIR /opt
|
4 |
+
|
5 |
+
RUN apt-get update \
|
6 |
+
&& apt install cmake clang swig gcc python3.11 python3-venv python3-dev -y \
|
7 |
+
&& rm -rf /var/lib/apt/lists/*
|
8 |
+
|
9 |
+
COPY ./Makefile /opt/Makefile
|
10 |
+
COPY ./pyproject.toml /opt/pyproject.toml
|
11 |
+
RUN make .venv
|
12 |
+
|
13 |
+
COPY ./src /opt/src
|
14 |
+
|
15 |
+
# Runtime args
|
16 |
+
CMD .venv/bin/python /opt/create_app.py
|
Makefile
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.venv:
|
2 |
+
python3 -m venv .venv
|
3 |
+
.venv/bin/pip install --upgrade pip
|
4 |
+
.venv/bin/pip install .
|
Readme.md
ADDED
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
title: Connect4
|
3 |
+
emoji: 🌐
|
4 |
+
colorFrom: blue
|
5 |
+
colorTo: yellow
|
6 |
+
sdk: docker
|
7 |
+
pinned: false
|
8 |
+
license: mit
|
9 |
+
---
|
10 |
+
|
11 |
+
frontend adapted from [github](https://github.com/jprioses/connect-four-game)
|
12 |
+
|
13 |
+
Check out the configuration reference at [huggingface](https://huggingface.co/docs/hub/spaces-config-reference)
|
14 |
+
|
15 |
+
## TODO
|
16 |
+
|
17 |
+
link to github repo
|
18 |
+
|
19 |
+
test block forced move
|
20 |
+
|
21 |
+
Connect to AWS database https://aws.amazon.com/rds/?p=ft&c=db&z=3
|
22 |
+
using alembic and sqlmodel
|
pyproject.toml
ADDED
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
[build-system]
|
2 |
+
requires = ["setuptools"]
|
3 |
+
build-backend = "setuptools.build_meta"
|
4 |
+
|
5 |
+
[project]
|
6 |
+
name = "connect4-backend"
|
7 |
+
version = "0.0.1"
|
8 |
+
authors = [
|
9 |
+
{ name="Clement Gohlke"},
|
10 |
+
]
|
11 |
+
readme = "README.md"
|
12 |
+
requires-python = ">=3.11"
|
13 |
+
classifiers = [
|
14 |
+
"Programming Language :: Python :: 3",
|
15 |
+
"License :: OSI Approved :: MIT License",
|
16 |
+
"Operating System :: OS Independent",
|
17 |
+
]
|
18 |
+
dependencies = [
|
19 |
+
"tensordict @ git+https://github.com/pytorch/tensordict.git@c3caa7612275306ce72697a82d5252681ddae0ab",
|
20 |
+
"torchrl @ git+https://github.com/pytorch/rl.git@1bb192e0f3ad9e7b8c6fa769bfa3bb9d82ca4f29", # torchrl not found in docker, using 0.2.1
|
21 |
+
"litrl~=0.0.9",
|
22 |
+
"fastapi==0.104.1",
|
23 |
+
"uvicorn==0.25.0",
|
24 |
+
"moviepy==1.0.3",
|
25 |
+
]
|
26 |
+
[project.optional-dependencies]
|
27 |
+
test = [
|
28 |
+
"pytest==7.4.4",
|
29 |
+
"mypy==1.8.0",
|
30 |
+
"httpx==0.26.0"
|
31 |
+
]
|
32 |
+
|
33 |
+
[tool.pytest.ini_options]
|
34 |
+
pythonpath = [
|
35 |
+
"."
|
36 |
+
]
|