-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathfloydhub-documentation.html
290 lines (217 loc) · 9.32 KB
/
floydhub-documentation.html
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
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
<!DOCTYPE html>
<html lang="en">
<head>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'UA-112480279-1');
</script>
<meta charset="utf-8">
<title>channelCS - Floydhub Documentation</title>
<meta name="description" content="">
<meta name="author" content="channelCS">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script src="/theme/html5.js"></script>
<![endif]-->
<!-- Le styles -->
<link href="/theme/bootstrap.min.css" rel="stylesheet">
<link href="/theme/bootstrap.min.responsive.css" rel="stylesheet">
<link href="/theme/local.css" rel="stylesheet">
<link href="/theme/pygments.css" rel="stylesheet">
<!-- So Firefox can bookmark->"abo this site" -->
<link href="/feeds/all.atom.xml" rel="alternate" title="channelCS" type="application/atom+xml">
</head>
<body>
<div class="navbar">
<div class="navbar-inner">
<div class="container">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<a class="brand" href="">channelCS</a>
<div class="nav-collapse">
<ul class="nav">
</ul>
</div>
</div>
</div>
</div>
<div class="container">
<div class="content">
<div class="row">
<div class="span9">
<div class='article'>
<div class="content-title">
<h1>Floydhub Documentation</h1>
Sun 20 August 2017
by <a class="url fn" href="/author/aditya-arora-akshita-gupta.html">Aditya Arora, Akshita Gupta</a>
</div>
<div><h6></h6>
<p>Floyd is a great cloud computing platform.I have used it for running a lot of my deep learning models. The main advantage of using Floyd is that you don't require a <strong>Credit Card</strong> and that is the main reason for giving a try to Floyd. </p>
<p>Floyd has a pretty handy <em>documentation</em> at
<a href="http://docs.floydhub.com/" title="Floyd's Documentation">Floydhub</a> which is updated at regular intervals.</p>
<p>Initiallly I wrote this blog when there were a lot of confusions but now it is a very crisp and easy to use docs page.
This post contains steps to Get up and running with Floyd on Windows.</p>
<h2>Python Machine Learning Setting up Floyd</h2>
<p>Setting up floyd for using on Windows.</p>
<h3>Account</h3>
<p>Make your account at
<a href="https://www.floydhub.com/" title="Floyd's Homepage">Floydhub</a>.</p>
<p>You can get a free account which gives 10GB of storage and 20 hours of CPU time.
You can upgrade to any of their paid plans if you want to use their GPU and continue using their services.</p>
<h3>Installation</h3>
<p>Install the <code>floyd-cli</code> using</p>
<div class="highlight"><pre><span></span>$ pip install -U floyd-cli
</pre></div>
<h3>Login</h3>
<p>Make sure you are logged in to your browser before continuing with this step.</p>
<div class="highlight"><pre><span></span>$ floyd login
</pre></div>
<p>Copy and paste your authentication token in your terminal</p>
<h2>Run project</h2>
<ol>
<li>
<p><strong>Make a project folder</strong></p>
<div class="highlight"><pre><span></span>$ mkdir myproject
</pre></div>
</li>
<li>
<p><strong>Change to project folder</strong></p>
<div class="highlight"><pre><span></span>$ <span class="nb">cd</span> myproject
</pre></div>
</li>
<li>
<p><strong>Make a folder for data</strong></p>
<div class="highlight"><pre><span></span>$ mkdir <mydata>
</pre></div>
</li>
<li>
<p><strong>Make a folder for code</strong></p>
<div class="highlight"><pre><span></span>$ mkdir <mycode>
</pre></div>
<p>Paste all your data in <code><mydata></code> and your code in <code><mycode></code>.</p>
</li>
<li>
<p><strong>Change to data directory</strong></p>
<div class="highlight"><pre><span></span>$ <span class="nb">cd</span> <mydata>
</pre></div>
</li>
<li>
<p><strong>Initialise data</strong></p>
<div class="highlight"><pre><span></span>$ floyd data init sent-data
</pre></div>
</li>
<li>
<p><strong>Upload your dataset to Floyd</strong></p>
<div class="highlight"><pre><span></span>$ floyd data upload
</pre></div>
<p>Floyd will generate a data id for the uploaded dataset. This uploaded dataset can be used in your future experiments, if needed, using this data id.
<br /><strong>Output</strong></p>
<div class="highlight"><pre><span></span>Creating data source. Uploading files ...
DATA ID NAME VERSION
---------------------- -------------------- ---------
GY3QRFFUA8KpbnqvroTPPW alice/sent-data:1 1
</pre></div>
</li>
<li>
<p><strong>Change to the code directory</strong></p>
<div class="highlight"><pre><span></span>$ <span class="nb">cd</span> ../mycode
</pre></div>
</li>
<li>
<p><strong>Run the code</strong></p>
<div class="highlight"><pre><span></span>$ floyd run --data <DATA_KEY>:<MOUNT> --env theano-0.9:py2 <span class="s2">"python filename.py"</span>
</pre></div>
<p>This would run the code in the cloud.<br /><strong>Example code</strong></p>
<div class="highlight"><pre><span></span>$ floyd run --data GY3QRFFUA8KpbnqvroTPPW:mydata --env theano-0.9:py2 <span class="s2">"python mlp.py"</span>
</pre></div>
</li>
<li>
<p><strong>Check the status of code</strong></p>
<div class="highlight"><pre><span></span>$ floyd logs <RUN_ID>
</pre></div>
</li>
</ol>
<h3>Some common problems:</h3>
<ul>
<li>Should I put my code and data in separate folders</li>
</ul>
<p><strong>Note</strong>: Adding the codes in a separate folder prevents re-loading of data in the memory of floyd server.
Floyd server synchronizes the WHOLE FOLDER in which the code is located when you run the code using the above command, which is actually a waste of (upload) time and a problem of data redundancy as you have already uploaded the data on the server.</p>
<ul>
<li>How to link data in my script<div class="highlight"><pre><span></span>x_data = np.load('/nfiles/fileone.npy')
y_data = np.load('/nfiles/filetwo.npy')
</pre></div>
</li>
</ul>
<p>Here, nfiles is my MOUNT point.</p>
<ul>
<li>If you are using Anaconda prompt and you come across the following error after running the command: "pip install -U floyd-cli": scandir could not be installed<div class="highlight"><pre><span></span>$ conda install -c conda-forge <span class="nv">scandir</span><span class="o">=</span><span class="m">1</span>.5
</pre></div>
</li>
</ul>
<p>If you have any issues kindly raise an issue in the <a href="https://github.com/channelCS/channelcs.github.io">GitHub</a> repo.</p></div>
<hr>
<h2>Comments</h2>
<div id="disqus_thread"></div>
<script type="text/javascript">
var disqus_shortname = 'channelcsgit';
var disqus_title = 'Floydhub Documentation';
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = 'https://' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</script>
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
</div>
</div>
<div class="span3">
<div class="well" style="padding: 8px 0; background-color: #FBFBFB;">
<ul class="nav nav-list">
<li class="nav-header">
Site
</li>
<li><a href="/archives.html">Archives</a>
<li><a href="/tags.html">Tags</a>
<li><a href="/feeds/all.atom.xml" rel="alternate">Atom feed</a></li>
</ul>
</div>
<div class="well" style="padding: 8px 0; background-color: #FBFBFB;">
<ul class="nav nav-list">
<li class="nav-header">
Categories
</li>
<li><a href="/category/audio-processing.html">Audio Processing</a></li>
<li><a href="/category/deep-learning.html">Deep Learning</a></li>
<li><a href="/category/docs.html">Docs</a></li>
<li><a href="/category/github.html">Github</a></li>
<li><a href="/category/main.html">main</a></li>
<li><a href="/category/outreachy.html">Outreachy</a></li>
</ul>
</div>
<div class="well" style="padding: 8px 0; background-color: #FBFBFB;">
<ul class="nav nav-list">
<li class="nav-header">
Links
</li>
<li><a href="http://github.com/channelCS">Github</a></li>
<li><a href="http://github.com/Deeplearn-lab">Deeplearn-lab</a></li>
</ul>
</div>
</div>
</div> </div>
<footer>
<br />
<p><a href="">channelCS</a> © channelCS 2018</p>
</footer>
</div> <!-- /container -->
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script src="/theme/bootstrap-collapse.js"></script>
</body>
</html>