-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPackage.swift
143 lines (104 loc) · 6.25 KB
/
Package.swift
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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
// swift-tools-version:5.4
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
let package = Package(
name: "deep-learning-with-swift-for-tensorflow-book",
platforms: [
.macOS(.v11),
],
products: [],
dependencies: [
.package(url: "https://github.com/tensorflow/swift-models", .branch("main")),
],
targets: [
// MARK: Chapter 3: Differentiable Programming
.executableTarget(name: "AdvancedOperators",
path: "Sources/DifferentiableProgramming/AdvancedOperators"),
.executableTarget(name: "AlgorithmicDifferentiation",
path: "Sources/DifferentiableProgramming/AlgorithmicDifferentiation"),
.executableTarget(name: "Arrays",
path: "Sources/DifferentiableProgramming/Arrays"),
.executableTarget(name: "Classes",
path: "Sources/DifferentiableProgramming/Classes"),
.executableTarget(name: "Closures",
path: "Sources/DifferentiableProgramming/Closures"),
.executableTarget(name: "ConditionalStatements",
path: "Sources/DifferentiableProgramming/ConditionalStatements"),
.executableTarget(name: "ControlTransfer",
path: "Sources/DifferentiableProgramming/ControlTransfer"),
.executableTarget(name: "Dictionaries",
path: "Sources/DifferentiableProgramming/Dictionaries"),
.executableTarget(name: "Differentiation",
path: "Sources/DifferentiableProgramming/Differentiation"),
.executableTarget(name: "EarlyExit",
path: "Sources/DifferentiableProgramming/EarlyExit"),
.executableTarget(name: "Enumerations",
path: "Sources/DifferentiableProgramming/Enumerations"),
.executableTarget(name: "ErrorHandling",
path: "Sources/DifferentiableProgramming/ErrorHandling"),
.executableTarget(name: "Extensions",
path: "Sources/DifferentiableProgramming/Extensions"),
.executableTarget(name: "Generics",
path: "Sources/DifferentiableProgramming/Generics"),
.executableTarget(name: "GlobalFunctions",
path: "Sources/DifferentiableProgramming/GlobalFunctions"),
.executableTarget(name: "Loops",
path: "Sources/DifferentiableProgramming/Loops"),
.executableTarget(name: "NestedFunctions",
path: "Sources/DifferentiableProgramming/NestedFunctions"),
.executableTarget(name: "Protocols",
path: "Sources/DifferentiableProgramming/Protocols"),
.executableTarget(name: "PythonInteroperability",
path: "Sources/DifferentiableProgramming/PythonInteroperability"),
.executableTarget(name: "Sets",
path: "Sources/DifferentiableProgramming/Sets"),
.executableTarget(name: "Structures",
path: "Sources/DifferentiableProgramming/Structures"),
.executableTarget(name: "Values",
path: "Sources/DifferentiableProgramming/Values"),
// MARK: Chapter 4: TensorFlow Basics
.executableTarget(name: "EpochAndBatches",
dependencies: [
.product(name: "Datasets", package: "swift-models")
],
path: "Sources/TensorFlowBasics/EpochAndBatches"),
.executableTarget(name: "FromScratchForResearch",
dependencies: [
.product(name: "Datasets", package: "swift-models"),
.product(name: "TrainingLoop", package: "swift-models"),
],
path: "Sources/TensorFlowBasics/FromScratchForResearch"),
.executableTarget(name: "ModelDefinition",
path: "Sources/TensorFlowBasics/ModelDefinition"),
.executableTarget(name: "TensorExplanation",
path: "Sources/TensorFlowBasics/TensorExplanation"),
.executableTarget(name: "TrainingAndTesting",
dependencies: [
.product(name: "Checkpoints", package: "swift-models"),
.product(name: "Datasets", package: "swift-models"),
],
path: "Sources/TensorFlowBasics/TrainingAndTesting"),
.executableTarget(name: "TrainingLoopExample",
dependencies: [
.product(name: "Datasets", package: "swift-models"),
.product(name: "TrainingLoop", package: "swift-models"),
],
path: "Sources/TensorFlowBasics/TrainingLoopExample"),
// MARK: Chapter 5: Neural Networks
.executableTarget(name: "InputOptimization",
path: "Sources/NeuralNetworks/InputOptimization"),
.executableTarget(name: "LinearRegression",
path: "Sources/NeuralNetworks/LinearRegression"),
.executableTarget(name: "ParametersOptimization",
path: "Sources/NeuralNetworks/ParametersOptimization"),
.executableTarget(name: "PolynomialRegression",
path: "Sources/NeuralNetworks/PolynomialRegression"),
// MARK: Chapter 6: Computer Vision
.executableTarget(name: "ImageRecognition",
dependencies: [
.product(name: "Datasets", package: "swift-models"),
.product(name: "TrainingLoop", package: "swift-models"),
],
path: "Sources/ComputerVision/ImageRecognition"),
]
)