Skip to content

Commit f8e659e

Browse files
authored
Merge pull request #10 from EntropyOrg/binder
Add Binder configuration
2 parents f75ff98 + 76f57bf commit f8e659e

File tree

4 files changed

+36
-0
lines changed

4 files changed

+36
-0
lines changed

.binder/apt.txt

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
perl
2+
cpanminus
3+
libffi-dev
4+
libzmq5
5+
libjpeg-dev
6+
libpng-dev
7+
libgsl-dev

.binder/postBuild

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#!/bin/bash
2+
3+
set -exu
4+
5+
export MAKEFLAGS="-j$(nproc)"
6+
export CPM_WORKERS=$(nproc)
7+
8+
cpanm --local-lib=~/perl5 -nq local::lib && eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib)
9+
cpanm -nq App::cpm
10+
11+
KERNEL="Devel::IPerl"
12+
MODULES="AI::TensorFlow::Libtensorflow"
13+
ALL_MODULES="$KERNEL $MODULES"
14+
15+
cpm install -g -w $CPM_WORKERS $ALL_MODULES \
16+
|| cpanm -nq $ALL_MODULES
17+
18+
cpm install -g -w $CPM_WORKERS --cpanfile=<( \
19+
awk '/=head1 CPANFILE/,EOF {print}' < lib/AI/TensorFlow/Libtensorflow/Manual/InferenceUsingTFHubMobileNetV2Model.pod \
20+
| awk 'NR>1' \
21+
)
22+
23+
iperl --version # install kernel and exit

.binder/start

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/bin/bash
2+
3+
eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib)
4+
5+
exec "$@"

requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
tensorflow

0 commit comments

Comments
 (0)