-
Notifications
You must be signed in to change notification settings - Fork 78
Expand file tree
/
Copy pathindex.tsx
More file actions
105 lines (101 loc) · 2.89 KB
/
index.tsx
File metadata and controls
105 lines (101 loc) · 2.89 KB
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
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
import { useRouter } from 'expo-router';
import { View, Text, StyleSheet, TouchableOpacity } from 'react-native';
import ColorPalette from '../colors';
import ExecutorchLogo from '../assets/icons/executorch.svg';
export default function Home() {
const router = useRouter();
return (
<View style={styles.container}>
<ExecutorchLogo width={64} height={64} />
<Text style={styles.headerText}>Select a demo model</Text>
<View style={styles.buttonContainer}>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('vision_camera/')}
>
<Text style={styles.buttonText}>Vision Camera</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('classification/')}
>
<Text style={styles.buttonText}>Classification</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('semantic_segmentation/')}
>
<Text style={styles.buttonText}>Semantic Segmentation</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('object_detection/')}
>
<Text style={styles.buttonText}>Object Detection</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('ocr/')}
>
<Text style={styles.buttonText}>OCR</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('ocr_vertical/')}
>
<Text style={styles.buttonText}>OCR Vertical</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('style_transfer/')}
>
<Text style={styles.buttonText}>Style Transfer</Text>
</TouchableOpacity>
<TouchableOpacity
style={styles.button}
onPress={() => router.navigate('text_to_image/')}
>
<Text style={styles.buttonText}>Image Generation</Text>
</TouchableOpacity>
</View>
</View>
);
}
export const fontSizes = {
xxl: 34,
xl: 22,
lg: 18,
md: 16,
sm: 14,
xs: 12,
xxs: 10,
};
const styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: '#fff',
},
headerText: {
fontSize: fontSizes.lg,
color: ColorPalette.strongPrimary,
margin: 20,
},
buttonContainer: {
width: '80%',
justifyContent: 'space-evenly',
marginBottom: 20,
},
button: {
backgroundColor: ColorPalette.strongPrimary,
borderRadius: 8,
padding: 10,
alignItems: 'center',
marginBottom: 10,
},
buttonText: {
color: 'white',
fontSize: fontSizes.md,
},
});