File tree 1 file changed +29
-0
lines changed
1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,16 @@ in parallel, respectively:
60
60
fpm build --compiler caf --flag "-cpp -DCAF -O3 -ffast-math"
61
61
```
62
62
63
+ #### Testing with fpm
64
+
65
+ ```
66
+ fpm test --flag "-cpp -O3 -ffast-math -fcoarray=single"
67
+ ```
68
+
69
+ For the time being, you need to specify the same compiler flags to ` fpm test `
70
+ as you did in ` fpm build ` so that fpm can figure out to use the same build
71
+ profile.
72
+
63
73
See [ Fortran Package Manager] ( https://github.com/fortran-lang/fpm ) for more info on fpm.
64
74
65
75
### Building with CMake
@@ -135,6 +145,25 @@ To build with debugging flags enabled, type:
135
145
cmake .. -DCMAKE_BUILD_TYPE=debug
136
146
```
137
147
148
+ #### Running tests with CMake
149
+
150
+ Before running the tests, link the the data/ directory to the current directory:
151
+
152
+ ```
153
+ ln -s ../data
154
+ ```
155
+
156
+ The MNIST dataset which comes with the code as a tarball must be unpacked first.
157
+ See [ MNIST training example] ( #mnist-training-example ) on how to do that.
158
+ Once the MNIST dataset is unpacked and the data/ directory is linked in your
159
+ CMake build/ directory, run
160
+
161
+ ```
162
+ ctest
163
+ ```
164
+
165
+ to run the tests.
166
+
138
167
## Examples
139
168
140
169
### Creating a network
You can’t perform that action at this time.
0 commit comments