Guest User

Untitled

a guest
Oct 19th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.60 KB | None | 0 0
  1. {
  2. "cells": [
  3. {
  4. "cell_type": "code",
  5. "execution_count": 1,
  6. "metadata": {},
  7. "outputs": [],
  8. "source": [
  9. "x = sorted(plwordprobs['aws'].items(), key=operator.itemgetter(1) ,reverse=True)[:15]\n",
  10. "y = sorted(plwordprobs['watson'].items(), key=operator.itemgetter(1) ,reverse=True)[:15]\n",
  11. "z = sorted(plwordprobs['azure'].items(), key=operator.itemgetter(1) ,reverse=True)[:15]"
  12. ]
  13. },
  14. {
  15. "cell_type": "code",
  16. "execution_count": 2,
  17. "metadata": {},
  18. "outputs": [
  19. {
  20. "name": "stdout",
  21. "output_type": "stream",
  22. "text": [
  23. "aws watson azure\n",
  24. "('data', 0.024794) ('df', 0.018522) ('import', 0.013169)\n",
  25. "('import', 0.016117) ('tf', 0.013373) ('data', 0.01199)\n",
  26. "('train', 0.015771) ('import', 0.012989) ('tf', 0.011484)\n",
  27. "('name', 0.011901) ('data', 0.011951) ('plt', 0.00994)\n",
  28. "('test', 0.011627) ('train', 0.011183) ('print', 0.009603)\n",
  29. "('sagemaker', 0.010771) ('test', 0.009492) ('model', 0.009603)\n",
  30. "('the', 0.010474) ('print', 0.009377) ('the', 0.008817)\n",
  31. "('print', 0.009296) ('the', 0.008185) ('test', 0.008592)\n",
  32. "('endpoint', 0.008938) ('in', 0.007724) ('name', 0.008564)\n",
  33. "('to', 0.008195) ('for', 0.007321) ('from', 0.008255)\n",
  34. "('s3', 0.007869) ('plt', 0.006898) ('in', 0.007834)\n",
  35. "('training', 0.007841) ('model', 0.006802) ('img', 0.007048)\n",
  36. "('in', 0.007327) ('as', 0.006514) ('for', 0.006964)\n",
  37. "('from', 0.007174) ('from', 0.006341) ('image', 0.006964)\n",
  38. "('for', 0.007122) ('to', 0.005995) ('as', 0.005953)\n"
  39. ]
  40. }
  41. ],
  42. "source": [
  43. "print('aws'.ljust(30), 'watson'.ljust(30), 'azure')\n",
  44. "for i in range(15):\n",
  45. " print(str(x[i]).ljust(30), str(y[i]).ljust(30), str(z[i]))"
  46. ]
  47. }
  48. ],
  49. "metadata": {
  50. "kernelspec": {
  51. "display_name": "Python 3",
  52. "language": "python",
  53. "name": "python3"
  54. },
  55. "language_info": {
  56. "codemirror_mode": {
  57. "name": "ipython",
  58. "version": 3
  59. },
  60. "file_extension": ".py",
  61. "mimetype": "text/x-python",
  62. "name": "python",
  63. "nbconvert_exporter": "python",
  64. "pygments_lexer": "ipython3",
  65. "version": "3.6.4"
  66. }
  67. },
  68. "nbformat": 4,
  69. "nbformat_minor": 2
  70. }
Add Comment
Please, Sign In to add comment