Rev 3655 Rev 3656
Line 169... Line 169...
169 }, 169 },
170 { 170 {
171 "cell_type": "markdown", 171 "cell_type": "markdown",
172 "metadata": {}, 172 "metadata": {},
173 "source": [ 173 "source": [
174 "Nyn\u00ed u\u017e m\u016f\u017eeme p\u0159\u00edmo komunikovat se za\u0159\u00edzen\u00edm pojmenovan\u00fdm jako gauge." 174 "Nyn\u00ed u\u017e m\u016f\u017eeme p\u0159\u00edmo komunikovat se za\u0159\u00edzen\u00edm pojmenovan\u00fdm jako acc."
175 ] 175 ]
176 }, 176 },
177 { 177 {
178 "cell_type": "code", 178 "cell_type": "code",
179 "collapsed": false, 179 "collapsed": false,
Line 181... Line 181...
181 "MEASUREMENTS = 1000\n", 181 "MEASUREMENTS = 1000\n",
182 "x = np.zeros(MEASUREMENTS)\n", 182 "x = np.zeros(MEASUREMENTS)\n",
183 "y = np.zeros(MEASUREMENTS)\n", 183 "y = np.zeros(MEASUREMENTS)\n",
184 "z = np.zeros(MEASUREMENTS)\n", 184 "z = np.zeros(MEASUREMENTS)\n",
185 "\n", 185 "\n",
186 "for n in range(MEASUREMENTS):\n", -  
187 "# acc.route() V p\u0159\u00edpad\u011b v\u00edce \u010didel je pot\u0159eba ke ka\u017ed\u00e9mu p\u0159ed jeho pou\u017eit\u00edm nechat vyroutovat cesutu na sb\u011brnici.\n", 186 "# acc.route() V p\u0159\u00edpad\u011b v\u00edce \u010didel je pot\u0159eba ke ka\u017ed\u00e9mu p\u0159ed jeho pou\u017eit\u00edm nechat vyroutovat cesutu na sb\u011brnici.\n",
-   187 "\n",
-   188 "for n in range(MEASUREMENTS):\n",
188 " (x[n], y[n], z[n]) = acc.axes()\n", 189 " (x[n], y[n], z[n]) = acc.axes()\n",
189 " print( n, x[n], y[n], z[n])" 190 " print( n, x[n], y[n], z[n])"
190 ], 191 ],
191 "language": "python", 192 "language": "python",
192 "metadata": {}, 193 "metadata": {},
Line 8203... Line 8204...
8203 "metadata": {}, 8204 "metadata": {},
8204 "outputs": [], 8205 "outputs": [],
8205 "prompt_number": 73 8206 "prompt_number": 73
8206 }, 8207 },
8207 { 8208 {
8208 "cell_type": "code", 8209 "cell_type": "markdown",
8209 "collapsed": false, -  
8210 "input": [ -  
8211 "from mpl_toolkits.mplot3d.axes3d import Axes3D" -  
8212 ], -  
8213 "language": "python", -  
8214 "metadata": {}, 8210 "metadata": {},
8215 "outputs": [], 8211 "source": [
-   8212 "Nam\u011b\u0159en\u00e1 data m\u016f\u017eeme tak\u00e9 z\u00edskat z p\u0159edem ulo\u017een\u00e9ho souboru. V n\u00e1sleduj\u00edc\u00edm bloku je otev\u0159en soubor s referen\u010dn\u00edmi daty. "
8216 "prompt_number": 53 8213 ]
8217 }, 8214 },
8218 { 8215 {
8219 "cell_type": "code", 8216 "cell_type": "code",
8220 "collapsed": false, 8217 "collapsed": false,
8221 "input": [ 8218 "input": [
Line 8225... Line 8222...
8225 "z=data['z']" 8222 "z=data['z']"
8226 ], 8223 ],
8227 "language": "python", 8224 "language": "python",
8228 "metadata": {}, 8225 "metadata": {},
8229 "outputs": [], 8226 "outputs": [],
8230 "prompt_number": 74 8227 "prompt_number": 1
8231 }, 8228 },
8232 { 8229 {
8233 "cell_type": "code", 8230 "cell_type": "code",
8234 "collapsed": false, 8231 "collapsed": false,
8235 "input": [ 8232 "input": [
-   8233 "from mpl_toolkits.mplot3d.axes3d import Axes3D\n",
8236 "%pylab qt\n", 8234 "%pylab qt\n",
8237 "#%pylab inline\n", 8235 "#%pylab inline\n",
8238 "#x, y, z) = np.load('./calibration_data_set.npz')\n", -  
8239 "fig = plt.figure()\n", 8236 "fig = plt.figure()\n",
8240 "ax = Axes3D(fig)\n", 8237 "ax = Axes3D(fig)\n",
8241 "p = ax.scatter(x, y, z)\n", 8238 "p = ax.scatter(x, y, z)\n",
8242 "#pyplot.show()\n" 8239 "#pyplot.show()\n"
8243 ], 8240 ],
Line 8250... Line 8247...
8250 "text": [ 8247 "text": [
8251 "Populating the interactive namespace from numpy and matplotlib\n" 8248 "Populating the interactive namespace from numpy and matplotlib\n"
8252 ] 8249 ]
8253 } 8250 }
8254 ], 8251 ],
8255 "prompt_number": 76 8252 "prompt_number": 3
8256 }, 8253 },
8257 { 8254 {
8258 "cell_type": "code", 8255 "cell_type": "code",
8259 "collapsed": false, 8256 "collapsed": false,
8260 "input": [ 8257 "input": [