-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschemas.py
89 lines (70 loc) · 1.35 KB
/
schemas.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
from pydantic import BaseModel
class SketchBox(BaseModel):
x1: float
y1: float
x2: float
y2: float
class RGB(BaseModel):
red: int
green: int
blue: int
class VideoBase(BaseModel):
video_id: str
description: str
title: str
vimeo_id: str
class Tags(BaseModel):
video_id: str
tag: str
class Text(BaseModel):
keyframe_id: str
text: str
video_id: str
start_frame: int
start_time: float
class Config:
orm_mode = True
class TextInput(BaseModel):
text: str
class ColorSketchInput(BaseModel):
color: RGB
box: SketchBox
object: str
max_results: int
class ColorInput(BaseModel):
c0: RGB
c1: RGB
c2: RGB
c3: RGB
c4: RGB
c5: RGB
c6: RGB
c7: RGB
c8: RGB
c9: RGB
c10: RGB
c11: RGB
max_results: int
class ObjectSketchInput(BaseModel):
object: str
sketch: SketchBox
max_results: int
class DoubleObjectSketchInput(BaseModel):
object1: str
sketch1: SketchBox
object2: str
sketch2: SketchBox
max_results: int
class ThreeObjectSketchInput(BaseModel):
object1: str
sketch1: SketchBox
object2: str
sketch2: SketchBox
object3: str
sketch3: SketchBox
max_results: int
class Test(BaseModel):
test: RGB
class ObjectNumber(BaseModel):
object: str
number: int