├── .gitignore ├── dse-studio ├── DO_NOT_DELETE_EXAMPLE_CONNECTION! ├── connections │ ├── .418ed742-cd61-4df8-abd8-07bc56a62e8d.example │ └── 418ed742-cd61-4df8-abd8-07bc56a62e8d └── notebooks │ ├── 3a0a2fc4-d7d7-40ba-9438-8d672da3c1d4 │ ├── 3a0a2fc4-d7d7-40ba-9438-8d672da3c1d3 │ ├── 3a0a2fc4-d7d7-40ba-9438-8d672da3c1d6 │ ├── 3a0a2fc4-d7d7-40ba-9438-8d672da3c1d5 │ ├── 3a0a2fc4-d7d7-40ba-9438-8d672da3c1d7 │ └── 3a0a2fc4-d7d7-40ba-9438-8d672da3c1d2 ├── jupyter ├── images │ ├── dse.png │ ├── wine.png │ ├── bttf3.jpg │ ├── dselogo.png │ ├── volvo.jpg │ ├── wines.jpeg │ ├── hondaHRV.png │ ├── laughing.gif │ ├── seinfeld.jpg │ ├── sparklogo.png │ ├── titlePage.png │ ├── drinkWine.jpeg │ ├── getTheLikes.png │ ├── pixarMovies.jpg │ ├── socialMedia.jpeg │ ├── whiteAndRed.jpeg │ ├── chocolatePic.jpeg │ ├── wineAndChocolate.jpg │ ├── init94.html │ └── init43.html ├── Collaborative Filtering.ipynb ├── Random Forest.ipynb ├── Naivebayes.ipynb ├── kmeans.ipynb ├── FP-Growth.ipynb └── data │ └── car_evaluation.csv ├── pyspark-cassandra └── Dockerfile ├── slides ├── CodeLabs_Cassandra.pdf └── Intro to ML with C_ and Spark.pdf ├── README.md └── docker-compose.yml /.gitignore: -------------------------------------------------------------------------------- 1 | jupyter/.* 2 | -------------------------------------------------------------------------------- /dse-studio/DO_NOT_DELETE_EXAMPLE_CONNECTION!: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /dse-studio/connections/.418ed742-cd61-4df8-abd8-07bc56a62e8d.example: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /jupyter/images/dse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/dse.png -------------------------------------------------------------------------------- /jupyter/images/wine.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/wine.png -------------------------------------------------------------------------------- /jupyter/images/bttf3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/bttf3.jpg -------------------------------------------------------------------------------- /jupyter/images/dselogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/dselogo.png -------------------------------------------------------------------------------- /jupyter/images/volvo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/volvo.jpg -------------------------------------------------------------------------------- /jupyter/images/wines.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/wines.jpeg -------------------------------------------------------------------------------- /jupyter/images/hondaHRV.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/hondaHRV.png -------------------------------------------------------------------------------- /jupyter/images/laughing.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/laughing.gif -------------------------------------------------------------------------------- /jupyter/images/seinfeld.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/seinfeld.jpg -------------------------------------------------------------------------------- /jupyter/images/sparklogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/sparklogo.png -------------------------------------------------------------------------------- /jupyter/images/titlePage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/titlePage.png -------------------------------------------------------------------------------- /pyspark-cassandra/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM jupyter/pyspark-notebook 2 | USER root 3 | RUN pip install cassandra-driver 4 | USER jovyan 5 | -------------------------------------------------------------------------------- /jupyter/images/drinkWine.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/drinkWine.jpeg -------------------------------------------------------------------------------- /jupyter/images/getTheLikes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/getTheLikes.png -------------------------------------------------------------------------------- /jupyter/images/pixarMovies.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/pixarMovies.jpg -------------------------------------------------------------------------------- /jupyter/images/socialMedia.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/socialMedia.jpeg -------------------------------------------------------------------------------- /jupyter/images/whiteAndRed.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/whiteAndRed.jpeg -------------------------------------------------------------------------------- /slides/CodeLabs_Cassandra.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/slides/CodeLabs_Cassandra.pdf -------------------------------------------------------------------------------- /jupyter/images/chocolatePic.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/chocolatePic.jpeg -------------------------------------------------------------------------------- /jupyter/images/wineAndChocolate.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/jupyter/images/wineAndChocolate.jpg -------------------------------------------------------------------------------- /slides/Intro to ML with C_ and Spark.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/datastaxdevs/workshop-machine-learning/master/slides/Intro to ML with C_ and Spark.pdf -------------------------------------------------------------------------------- /dse-studio/connections/418ed742-cd61-4df8-abd8-07bc56a62e8d: -------------------------------------------------------------------------------- 1 | json_connection_configuration_v1{"1":"418ed742-cd61-4df8-abd8-07bc56a62e8d","10":"default localhost","11":9042,"12":["dse"],"15":0,"19":{"1":{}},"20":{}} -------------------------------------------------------------------------------- /jupyter/images/init94.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | A Joke 4 | 5 | 6 | 7 |
8 | 9 | 10 | 24 |
11 |
12 |
13 | 14 | Two atoms are walking down the street when one 15 | atom says to the other 16 | "Oh, my! I've lost an electron!" 17 |

18 | The second atom says"Are you sure" 19 |

20 | The first replies "I'm positive!" 21 | 22 | 23 |

25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /jupyter/images/init43.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | A Joke 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 23 |
12 |
13 |

    14 | 15 | Arnold Swartzeneger and Sylvester Stallone are making a movie about 16 | the lives of the great composers. 17 |

    Stallone says "I want to be Mozart." 18 |

    Swartzeneger says: "In that case... I'll be Bach." 19 | 20 |

21 | 22 |
24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Machine Learning with Apache Spark & Cassandra 2 | ## Cassandra + Spark = ❤️ 3 | 4 | A Hands-on Lab delivered by DataStax' Developer Advocates team. Want to learn the awesomness of distributed databases and computational systems? Jump in, watch the slides and do the practicals steps! 5 | 6 | ## Slides 7 | 8 | * [CodeLabs Cassandra+Spark](./slides/CodeLabs_Cassandra.pdf) 9 | * [Introduction to Machine Learning with Apache Cassandra and Apache Spark](./slides/Intro%20to%20ML%20with%20C_%20and%20Spark.pdf) 10 | 11 | ## Labs 12 | 13 | ### Reqs 14 | 15 | - git 16 | - docker 17 | - docker-compose 18 | 19 | ### Installation 20 | 21 | ``` 22 | git clone https://github.com/DataStax-Academy/machine-learning-workshop-online.git 23 | cd machine-learning-workshop-online 24 | docker-compose up -d 25 | ``` 26 | 27 | ### Usage 28 | 29 | - For the Cassandra labs, access DataStaxs Studio: http://localhost:9091 30 | - For the Spark labs, access Jupyter Notebooks: http://localhost:8888 password: `datastax` 31 | 32 | You may need to use some custom IP instead of localhost if you use docker-for-mac, docker-for-windows or similar installation. 33 | 34 | ### Known Issues 35 | 36 | In some cases executing the exercises may lead to memory issues, especially on weaker or non-Linux machines due to docker limitations on memory. If you have any issues with exercises after the first few, try to clean up and start again `docker-compose kill && docker-compose down && docker-compose up -d`. You may need to repeat steps of the notebook you were working on. 37 | -------------------------------------------------------------------------------- /dse-studio/notebooks/3a0a2fc4-d7d7-40ba-9438-8d672da3c1d4: -------------------------------------------------------------------------------- 1 | json_notebook_v1{"1":"4756dc37-249d-4e98-b8fe-41cf4ef8978d","10":"418ed742-cd61-4df8-abd8-07bc56a62e8d","11":"03 - Regression and Classification with Random Forest","12":{"1":1570529850,"2":243000000},"13":{"1":1570532819,"2":155000000},"14":false,"15":[{"1":"0112cc27-6547-47dd-ac80-302a8edfa775","10":4,"11":"
\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Regression and Classification with Random Forest
\n","12":"markdown","13":{"1":"c450fa4f-9d70-44e8-bd3e-1dc3d5aa6794","10":{"9":"

\n

\"line\"

\n

Regression and Classification with Random Forest

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"871b7ca1-e3dc-49cf-a511-728b0528af64","10":0,"11":"describe table accelerate.wines_random_forest;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"2ada985a-e324-4023-9fe7-659e8007224b","10":0,"11":"select * from accelerate.wines_random_forest;","12":"cql","16":true,"17":false,"25":"CL.ONE"}],"16":{"1":{}},"17":""} -------------------------------------------------------------------------------- /docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '3' 2 | services: 3 | dse: # DataStax Enterprise (Apache Cassandra + Apache Spark + much more) 4 | image: datastax/dse-server:6.7.4 5 | command: [ -s -k ] # Run with Search and Analytics capabilities enabled 6 | environment: 7 | DS_LICENSE: accept # Accept licence on start 8 | JVM_EXTRA_OPTS: -Xmx4g -Xms4g 9 | cap_add: 10 | - IPC_LOCK # Allow DSE to lock memory with mlock 11 | ulimits: 12 | memlock: -1 # Lock memory 13 | ports: 14 | - "4040:4040" 15 | - "7080:7080" 16 | - "7081:7081" 17 | - "8983:8983" 18 | - "9042:9042" 19 | - "9077:9077" 20 | - "10000:10000" 21 | jupyter: # Jupyter Notebook 22 | #build: ./pyspark-cassandra 23 | image: hadesarchitect/jupyter-pyspark-cassandra 24 | volumes: 25 | - ./jupyter:/home/jovyan 26 | ports: 27 | - "8888:8888" # Exposes port to be available externally 28 | environment: 29 | PYSPARK_SUBMIT_ARGS: '--packages com.datastax.spark:spark-cassandra-connector_2.11:2.4.1 --conf spark.cassandra.connection.host=dse pyspark-shell' 30 | command: start-notebook.sh --NotebookApp.password='sha1:a536879cf56d:a895a85b375e09f7d6a8211cdcd0e87f16aa4e60' 31 | studio: # Web interface for the Apache Cassandra and DataStax Enterprise 32 | image: datastax/dse-studio:6.7.0 33 | volumes: 34 | - ./dse-studio/connections:/var/lib/datastax-studio/connections/admin 35 | - ./dse-studio/notebooks:/opt/datastax-studio/examples/notebooks 36 | ports: 37 | - "9091:9091" # Exposes port to be available externally 38 | environment: 39 | DS_LICENSE: accept # Accept licence on start 40 | -------------------------------------------------------------------------------- /dse-studio/notebooks/3a0a2fc4-d7d7-40ba-9438-8d672da3c1d3: -------------------------------------------------------------------------------- 1 | json_notebook_v1{"1":"fe01ff48-a3ee-43e5-a0bc-213461b4782e","10":"418ed742-cd61-4df8-abd8-07bc56a62e8d","11":"01 - Clustering with K-means","12":{"1":1570516354,"2":490000000},"13":{"1":1570527738,"2":820000000},"14":false,"15":[{"1":"15ed76cb-5f09-4eda-8de7-09f2501f9ef3","10":4,"11":"
\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Clustering with K-means
\n","12":"markdown","13":{"1":"9f341ee2-f96a-4e9a-aa29-7f4aa516a291","10":{"9":"

\n

\"line\"

\n

Clustering with K-means

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"3899b63c-c03a-4646-96b2-419773bd06db","10":0,"11":"// Enter your DESCRIBE command here:\ndescribe keyspace accelerate;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"f50b607f-d98a-4d38-b27c-c590c0d944db","10":0,"11":"select social_type, num_angrys, num_comments, num_hahas, num_likes, num_loves \nfrom accelerate.socialmedia\nLIMIT 5;","12":"cql","16":true,"17":false,"25":"CL.ONE"}],"16":{"1":{}},"17":""} -------------------------------------------------------------------------------- /dse-studio/notebooks/3a0a2fc4-d7d7-40ba-9438-8d672da3c1d6: -------------------------------------------------------------------------------- 1 | json_notebook_v1{"1":"70be1fed-5e58-454b-8e2b-f779d12f9bad","10":"418ed742-cd61-4df8-abd8-07bc56a62e8d","11":"05 - Recommendation with Collaborative Filtering","12":{"1":1570534402,"2":202000000},"13":{"1":1570534935,"2":44000000},"14":false,"15":[{"1":"2bf3112d-b8d9-4620-87a9-ec8fa9c0905c","10":4,"11":"
\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Recommendation with Collaborative Filtering
\n","12":"markdown","13":{"1":"8000f2c2-888e-42e0-8ccc-8bdfaac5cd29","10":{"9":"

\n

\"line\"

\n

Recommendation with Collaborative Filtering

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"bc518ea6-1298-4858-bfef-7018bd84986f","10":0,"11":"describe table accelerate.jokes;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"785a48e7-e33c-45a9-95e4-927b7ae3ae89","10":0,"11":"select COUNT(*) from accelerate.jokes;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"eda66e82-6478-4e29-a9d0-0818a991243a","10":0,"11":"SELECT * FROM accelerate.jokes WHERE userid = 100;","12":"cql","16":true,"17":false,"25":"CL.ONE"}],"16":{"1":{}},"17":""} -------------------------------------------------------------------------------- /dse-studio/notebooks/3a0a2fc4-d7d7-40ba-9438-8d672da3c1d5: -------------------------------------------------------------------------------- 1 | json_notebook_v1{"1":"bec8e30e-48db-42d3-a776-6923bd727b80","10":"418ed742-cd61-4df8-abd8-07bc56a62e8d","11":"04 - Recommendation with FP-Growth","12":{"1":1570533056,"2":833000000},"13":{"1":1570534250,"2":687000000},"14":false,"15":[{"1":"9dd5cfae-640d-4974-9fee-57d8765a874a","10":4,"11":"
\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Recommendation with FP-Growth
\n","12":"markdown","13":{"1":"7229f3d3-32b3-4924-b9cc-0ea462a90cb3","10":{"9":"

\n

\"line\"

\n

Recommendation with FP-Growth

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"a479cfbe-a40a-4063-bace-90b4b33d652a","10":0,"11":"describe table accelerate.movies;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"b584c90c-618a-4326-85b5-c9b05707dcba","10":0,"11":"describe table accelerate.movieratings;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"5cabfd39-651e-4486-ad8e-2854f295dc5d","10":0,"11":"select * FROM accelerate.movieratings where rating > 3;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"c72d2deb-199c-488c-aca1-9b9836d87bdd","11":"CREATE SEARCH INDEX ON accelerate.movieratings;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"0c9d6f8a-11d0-4adf-a48c-9b6788d448e7","10":4,"11":"select * FROM accelerate.movieratings where rating > 3;","12":"cql","13":{"1":"d54a1649-2d6f-4dd1-b9ea-fa4df133e40c","10":{"127":"com.datastax.studio.notebook.serialization.model.ListWithNulls","3":0},"11":1,"12":false,"14":48},"16":true,"17":false,"25":"CL.ONE"}],"16":{"1":{}},"17":""} -------------------------------------------------------------------------------- /dse-studio/notebooks/3a0a2fc4-d7d7-40ba-9438-8d672da3c1d7: -------------------------------------------------------------------------------- 1 | json_notebook_v1{"1":"e009cf61-ec6d-40b4-a67c-a5e01de668f7","10":"418ed742-cd61-4df8-abd8-07bc56a62e8d","11":"02 - Classification with Naive Bayes","12":{"1":1570528854,"2":538000000},"13":{"1":1570529425,"2":974000000},"14":false,"15":[{"1":"83a874c5-46d4-4aaf-8ab9-6eadc046c309","10":4,"11":"
\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Classification with Naive Bayes
\n","12":"markdown","13":{"1":"5926f435-e9ae-427e-963c-3b8bcbe37936","10":{"9":"

\n

\"line\"

\n

Classification with Naive Bayes

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"107583a5-8861-4afd-8c37-ebdc1a6e23c2","10":0,"11":"// Enter your DESCRIBE command here:\ndescribe keyspace accelerate;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"721138ca-cf3d-4a7b-8099-c2f658e1cbea","10":0,"11":"select * from accelerate.wines LIMIT 10;","12":"cql","16":true,"17":false,"18":{},"22":452,"25":"CL.ONE"},{"1":"7b602bff-0412-4bc9-a243-24431e709960","10":0,"11":"select count(*) from accelerate.wines;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"5b14c787-84a9-4efe-8d74-2c3b1919fa35","10":0,"11":"select * from accelerate.wines WHERE quality > 5;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"1133174c-6f66-4b9d-b5c4-350e2a719ccc","10":0,"11":"CREATE SEARCH INDEX ON accelerate.wines;","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"e69cd3fb-b623-477f-a64c-30a29705c877","10":0,"11":"select * from accelerate.wines \nWHERE quality > 5;","12":"cql","16":true,"17":false,"25":"CL.ONE"}],"17":""} -------------------------------------------------------------------------------- /jupyter/Collaborative Filtering.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "# Demo 5: Collaborative Filtering and Comedy! \n", 8 | "------\n", 9 | "\n", 10 | "\n", 11 | "#### Real Dataset: http://eigentaste.berkeley.edu/dataset/ Dataset 2 \n", 12 | "#### Rate Jokes: http://eigentaste.berkeley.edu" 13 | ] 14 | }, 15 | { 16 | "cell_type": "markdown", 17 | "metadata": {}, 18 | "source": [ 19 | "## What are we trying to learn from this dataset?\n", 20 | "\n", 21 | "# QUESTION: Can Collaborative Filtering be used to find which jokes to recommend to our users?\n" 22 | ] 23 | }, 24 | { 25 | "cell_type": "code", 26 | "execution_count": null, 27 | "metadata": {}, 28 | "outputs": [], 29 | "source": [ 30 | "%matplotlib inline\n", 31 | "import matplotlib.pyplot as plt" 32 | ] 33 | }, 34 | { 35 | "cell_type": "code", 36 | "execution_count": null, 37 | "metadata": {}, 38 | "outputs": [], 39 | "source": [ 40 | "import pandas\n", 41 | "import cassandra\n", 42 | "import pyspark\n", 43 | "import re\n", 44 | "import os\n", 45 | "import matplotlib.pyplot as plt\n", 46 | "from IPython.display import IFrame\n", 47 | "from IPython.display import display, Markdown\n", 48 | "from pyspark.sql import SparkSession\n", 49 | "from pyspark.ml.evaluation import RegressionEvaluator\n", 50 | "from pyspark.ml.recommendation import ALS\n", 51 | "from pyspark.sql import Row" 52 | ] 53 | }, 54 | { 55 | "cell_type": "markdown", 56 | "metadata": {}, 57 | "source": [ 58 | "#### Helper function to have nicer formatting of Spark DataFrames" 59 | ] 60 | }, 61 | { 62 | "cell_type": "code", 63 | "execution_count": null, 64 | "metadata": {}, 65 | "outputs": [], 66 | "source": [ 67 | "#Helper for pretty formatting for Spark DataFrames\n", 68 | "def showDF(df, limitRows = 10, truncate = False):\n", 69 | " if(truncate):\n", 70 | " pandas.set_option('display.max_colwidth', 100)\n", 71 | " else:\n", 72 | " pandas.set_option('display.max_colwidth', -1)\n", 73 | " pandas.set_option('display.max_rows', limitRows)\n", 74 | " display(df.limit(limitRows).toPandas())\n", 75 | " pandas.reset_option('display.max_rows')" 76 | ] 77 | }, 78 | { 79 | "cell_type": "markdown", 80 | "metadata": {}, 81 | "source": [ 82 | "## Creating Tables and Loading Tables" 83 | ] 84 | }, 85 | { 86 | "cell_type": "markdown", 87 | "metadata": {}, 88 | "source": [ 89 | "### Connect to Cassandra" 90 | ] 91 | }, 92 | { 93 | "cell_type": "code", 94 | "execution_count": null, 95 | "metadata": {}, 96 | "outputs": [], 97 | "source": [ 98 | "from cassandra.cluster import Cluster\n", 99 | "\n", 100 | "cluster = Cluster(['dse'])\n", 101 | "session = cluster.connect()" 102 | ] 103 | }, 104 | { 105 | "cell_type": "markdown", 106 | "metadata": {}, 107 | "source": [ 108 | "### Create Demo Keyspace " 109 | ] 110 | }, 111 | { 112 | "cell_type": "code", 113 | "execution_count": null, 114 | "metadata": {}, 115 | "outputs": [], 116 | "source": [ 117 | "session.execute(\"\"\"\n", 118 | " CREATE KEYSPACE IF NOT EXISTS accelerate \n", 119 | " WITH REPLICATION = \n", 120 | " { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }\"\"\"\n", 121 | ")" 122 | ] 123 | }, 124 | { 125 | "cell_type": "markdown", 126 | "metadata": {}, 127 | "source": [ 128 | "### Set keyspace " 129 | ] 130 | }, 131 | { 132 | "cell_type": "code", 133 | "execution_count": null, 134 | "metadata": {}, 135 | "outputs": [], 136 | "source": [ 137 | "session.set_keyspace('accelerate')" 138 | ] 139 | }, 140 | { 141 | "cell_type": "markdown", 142 | "metadata": {}, 143 | "source": [ 144 | "### Create table called jokes. Our PRIMARY will need to be a unique composite key (userid, jokeid). This will result in an even distribution of the data and allow for each row to be unique. Remember we will have to utilize that PRIMARY KEY in our WHERE clause in any of our CQL queries. " 145 | ] 146 | }, 147 | { 148 | "cell_type": "code", 149 | "execution_count": null, 150 | "metadata": {}, 151 | "outputs": [], 152 | "source": [ 153 | "query = \"CREATE TABLE IF NOT EXISTS jokes \\\n", 154 | " (userid int, jokeid int, rating float, \\\n", 155 | " PRIMARY KEY (userid, jokeid))\"\n", 156 | "session.execute(query)" 157 | ] 158 | }, 159 | { 160 | "cell_type": "markdown", 161 | "metadata": {}, 162 | "source": [ 163 | "### What do these of these 3 columns represent: \n", 164 | "\n", 165 | "* **Column 1**: User id\n", 166 | "* **Column 2**: Joke id\n", 167 | "* **Column 3**: Rating of joke (-10.00 - 10.00) " 168 | ] 169 | }, 170 | { 171 | "cell_type": "markdown", 172 | "metadata": {}, 173 | "source": [ 174 | "### Load Jokes dataset from CSV file (jester_ratings3.csv)\n", 175 | "* This is a file I created from the *.dat file and I only have 10,000 rows -- dataset has over 1 million rows\n", 176 | "\n", 177 | "\n", 178 | "#### Insert all the Joke Rating Data into the table `jokes`" 179 | ] 180 | }, 181 | { 182 | "cell_type": "code", 183 | "execution_count": null, 184 | "metadata": {}, 185 | "outputs": [], 186 | "source": [ 187 | "fileName = 'data/jester_ratings3.csv'\n", 188 | "input_file = open(fileName, 'r')\n", 189 | "\n", 190 | "for line in input_file:\n", 191 | " jokeRow = line.split(',')\n", 192 | " query = \"INSERT INTO jokes (userid, jokeid, rating)\"\n", 193 | " \n", 194 | " query = query + \"VALUES (%s, %s, %s)\"\n", 195 | " \n", 196 | " session.execute(query, (int(jokeRow[0]), int(jokeRow[1]) , float(jokeRow[2]) ))" 197 | ] 198 | }, 199 | { 200 | "cell_type": "markdown", 201 | "metadata": {}, 202 | "source": [ 203 | "#### Do a select * on joke_table WHERE userid = x to verify that data was loaded into the table" 204 | ] 205 | }, 206 | { 207 | "cell_type": "code", 208 | "execution_count": null, 209 | "metadata": { 210 | "scrolled": true 211 | }, 212 | "outputs": [], 213 | "source": [ 214 | "query = 'SELECT * FROM jokes WHERE userid = 65'\n", 215 | "rows = session.execute(query)\n", 216 | "for row in rows:\n", 217 | " print (row.userid, row.jokeid, row.rating)" 218 | ] 219 | }, 220 | { 221 | "cell_type": "markdown", 222 | "metadata": {}, 223 | "source": [ 224 | "" 225 | ] 226 | }, 227 | { 228 | "cell_type": "markdown", 229 | "metadata": {}, 230 | "source": [ 231 | "### Finally time for Apache Spark! " 232 | ] 233 | }, 234 | { 235 | "cell_type": "markdown", 236 | "metadata": {}, 237 | "source": [ 238 | "#### Create a spark session that is connected to Cassandra. From there load each table into a Spark Dataframe and take a count of the number of rows in each." 239 | ] 240 | }, 241 | { 242 | "cell_type": "code", 243 | "execution_count": null, 244 | "metadata": {}, 245 | "outputs": [], 246 | "source": [ 247 | "spark = SparkSession.builder.appName('demo').master(\"local\").getOrCreate()\n", 248 | "\n", 249 | "jokeTable = spark.read.format(\"org.apache.spark.sql.cassandra\").options(table=\"jokes\", keyspace=\"accelerate\").load()\n", 250 | "\n", 251 | "print (\"Table Row Count: \")\n", 252 | "print (jokeTable.count())" 253 | ] 254 | }, 255 | { 256 | "cell_type": "markdown", 257 | "metadata": {}, 258 | "source": [ 259 | "#### Split dataset into training and testing set " 260 | ] 261 | }, 262 | { 263 | "cell_type": "code", 264 | "execution_count": null, 265 | "metadata": {}, 266 | "outputs": [], 267 | "source": [ 268 | "(training, test) = jokeTable.randomSplit([0.8, 0.2])\n", 269 | "\n", 270 | "training_df = training.withColumn(\"rating\", training.rating.cast('int'))\n", 271 | "testing_df = test.withColumn(\"rating\", test.rating.cast('int'))\n", 272 | "\n", 273 | "showDF(training_df)" 274 | ] 275 | }, 276 | { 277 | "cell_type": "markdown", 278 | "metadata": {}, 279 | "source": [ 280 | "### Setup for CFliter with ALS\n", 281 | "\n", 282 | "https://spark.apache.org/docs/latest/ml-collaborative-filtering.html" 283 | ] 284 | }, 285 | { 286 | "cell_type": "code", 287 | "execution_count": null, 288 | "metadata": {}, 289 | "outputs": [], 290 | "source": [ 291 | "als = ALS(maxIter=5, regParam=0.01, userCol=\"userid\", itemCol=\"jokeid\", ratingCol=\"rating\",\n", 292 | " coldStartStrategy=\"drop\")\n", 293 | "\n", 294 | "model = als.fit(training_df)" 295 | ] 296 | }, 297 | { 298 | "cell_type": "code", 299 | "execution_count": null, 300 | "metadata": {}, 301 | "outputs": [], 302 | "source": [ 303 | "# Evaluate the model by computing the RMSE on the test data\n", 304 | "predictions = model.transform(testing_df)\n", 305 | "\n", 306 | "# Generate top 10 joke recommendations for each user\n", 307 | "userRecs = model.recommendForAllUsers(10)\n", 308 | "\n", 309 | "showDF(userRecs)\n", 310 | "\n", 311 | "# Generate top 10 user recommendations for each joke\n", 312 | "jokeRecs = model.recommendForAllItems(10)" 313 | ] 314 | }, 315 | { 316 | "cell_type": "code", 317 | "execution_count": null, 318 | "metadata": {}, 319 | "outputs": [], 320 | "source": [ 321 | "showDF(userRecs.filter(userRecs.userid == 65))" 322 | ] 323 | }, 324 | { 325 | "cell_type": "code", 326 | "execution_count": null, 327 | "metadata": {}, 328 | "outputs": [], 329 | "source": [ 330 | "IFrame(src='images/init94.html', width=700, height=200)" 331 | ] 332 | }, 333 | { 334 | "cell_type": "code", 335 | "execution_count": null, 336 | "metadata": {}, 337 | "outputs": [], 338 | "source": [ 339 | "IFrame(src='images/init43.html', width=700, height=200)" 340 | ] 341 | } 342 | ], 343 | "metadata": { 344 | "kernelspec": { 345 | "display_name": "Python 3", 346 | "language": "python", 347 | "name": "python3" 348 | }, 349 | "language_info": { 350 | "codemirror_mode": { 351 | "name": "ipython", 352 | "version": 3 353 | }, 354 | "file_extension": ".py", 355 | "mimetype": "text/x-python", 356 | "name": "python", 357 | "nbconvert_exporter": "python", 358 | "pygments_lexer": "ipython3", 359 | "version": "3.7.3" 360 | } 361 | }, 362 | "nbformat": 4, 363 | "nbformat_minor": 2 364 | } 365 | -------------------------------------------------------------------------------- /jupyter/Random Forest.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "# Demo 3: Random Forest and DataStax Analytics\n", 8 | "------\n", 9 | "\n", 10 | "\n", 11 | "\n", 12 | "#### Dataset: https://archive.ics.uci.edu/ml/datasets/Wine+Quality" 13 | ] 14 | }, 15 | { 16 | "cell_type": "markdown", 17 | "metadata": {}, 18 | "source": [ 19 | "## What are we trying to learn from this dataset? \n", 20 | "\n", 21 | "# QUESTION: Can Random Forest be used to classify a wine’s rating score by its attributes?" 22 | ] 23 | }, 24 | { 25 | "cell_type": "code", 26 | "execution_count": null, 27 | "metadata": {}, 28 | "outputs": [], 29 | "source": [ 30 | "%matplotlib inline\n", 31 | "import matplotlib.pyplot as plt" 32 | ] 33 | }, 34 | { 35 | "cell_type": "code", 36 | "execution_count": null, 37 | "metadata": {}, 38 | "outputs": [], 39 | "source": [ 40 | "import pandas\n", 41 | "import cassandra\n", 42 | "import pyspark\n", 43 | "import re\n", 44 | "import os\n", 45 | "import random\n", 46 | "from random import randint, randrange\n", 47 | "import matplotlib.pyplot as plt\n", 48 | "from IPython.display import display, Markdown\n", 49 | "from pyspark.sql import SparkSession\n", 50 | "from pyspark.ml.classification import RandomForestClassifier\n", 51 | "from pyspark.ml.feature import IndexToString, StringIndexer, VectorAssembler\n", 52 | "from pyspark.ml.evaluation import MulticlassClassificationEvaluator" 53 | ] 54 | }, 55 | { 56 | "cell_type": "markdown", 57 | "metadata": {}, 58 | "source": [ 59 | "#### Helper function to have nicer formatting of Spark DataFrames" 60 | ] 61 | }, 62 | { 63 | "cell_type": "code", 64 | "execution_count": null, 65 | "metadata": {}, 66 | "outputs": [], 67 | "source": [ 68 | "#Helper for pretty formatting for Spark DataFrames\n", 69 | "def showDF(df, limitRows = 5, truncate = True):\n", 70 | " if(truncate):\n", 71 | " pandas.set_option('display.max_colwidth', 50)\n", 72 | " else:\n", 73 | " pandas.set_option('display.max_colwidth', -1)\n", 74 | " pandas.set_option('display.max_rows', limitRows)\n", 75 | " display(df.limit(limitRows).toPandas())\n", 76 | " pandas.reset_option('display.max_rows')" 77 | ] 78 | }, 79 | { 80 | "cell_type": "markdown", 81 | "metadata": {}, 82 | "source": [ 83 | "## Creating Tables and Loading Tables" 84 | ] 85 | }, 86 | { 87 | "cell_type": "markdown", 88 | "metadata": {}, 89 | "source": [ 90 | "### Connect to Cassandra" 91 | ] 92 | }, 93 | { 94 | "cell_type": "code", 95 | "execution_count": null, 96 | "metadata": {}, 97 | "outputs": [], 98 | "source": [ 99 | "from cassandra.cluster import Cluster\n", 100 | "\n", 101 | "cluster = Cluster(['dse'])\n", 102 | "session = cluster.connect()" 103 | ] 104 | }, 105 | { 106 | "cell_type": "markdown", 107 | "metadata": {}, 108 | "source": [ 109 | "### Create Demo Keyspace " 110 | ] 111 | }, 112 | { 113 | "cell_type": "code", 114 | "execution_count": null, 115 | "metadata": {}, 116 | "outputs": [], 117 | "source": [ 118 | "session.execute(\"\"\"\n", 119 | " CREATE KEYSPACE IF NOT EXISTS accelerate \n", 120 | " WITH REPLICATION = \n", 121 | " { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }\"\"\"\n", 122 | ")" 123 | ] 124 | }, 125 | { 126 | "cell_type": "markdown", 127 | "metadata": {}, 128 | "source": [ 129 | "### Set keyspace " 130 | ] 131 | }, 132 | { 133 | "cell_type": "code", 134 | "execution_count": null, 135 | "metadata": {}, 136 | "outputs": [], 137 | "source": [ 138 | "session.set_keyspace('accelerate')" 139 | ] 140 | }, 141 | { 142 | "cell_type": "markdown", 143 | "metadata": {}, 144 | "source": [ 145 | "### Create table called `wines`. Our PRIMARY will be a unique key (wineid) we generate for each row. This will have two datasets \"white\" and \"red\"" 146 | ] 147 | }, 148 | { 149 | "cell_type": "code", 150 | "execution_count": null, 151 | "metadata": {}, 152 | "outputs": [], 153 | "source": [ 154 | "query = \"CREATE TABLE IF NOT EXISTS wines \\\n", 155 | " (wineid int, fixedAcidity float, volatileAcidity float, citricAcid float, sugar float, \\\n", 156 | " chlorides float, freeSulfur float, totalSulfur float, density float, ph float, \\\n", 157 | " sulphates float, alcohol float, quality float, \\\n", 158 | " PRIMARY KEY (wineid))\"\n", 159 | "session.execute(query)" 160 | ] 161 | }, 162 | { 163 | "cell_type": "markdown", 164 | "metadata": {}, 165 | "source": [ 166 | "### What do these of these 12 columns represent: \n", 167 | "\n", 168 | "* **Fixed acidity**\n", 169 | "* **Volatile acidity**\n", 170 | "* **Citric Acid**\n", 171 | "* **Residual Sugar** \n", 172 | "* **Chlorides**\n", 173 | "* **Free sulfur dioxide** \n", 174 | "* **Total sulfur dioxide**\n", 175 | "* **Density** \n", 176 | "* **pH**\n", 177 | "* **Sulphates**\n", 178 | "* **Alcohol**\n", 179 | "* **Quality**" 180 | ] 181 | }, 182 | { 183 | "cell_type": "markdown", 184 | "metadata": {}, 185 | "source": [ 186 | "### Load 2 Wine Dataset -- White and Red\n", 187 | "" 188 | ] 189 | }, 190 | { 191 | "cell_type": "markdown", 192 | "metadata": {}, 193 | "source": [ 194 | "### Load Wine datasets from CSV file (winequality-red.csv winequality-white.csv)\n", 195 | "* No clean up was requried! How nice :)\n", 196 | "\n", 197 | "#### Insert all the Wine Data into the DSE table `wines`" 198 | ] 199 | }, 200 | { 201 | "cell_type": "code", 202 | "execution_count": null, 203 | "metadata": {}, 204 | "outputs": [], 205 | "source": [ 206 | "fileName = 'data/winequality-red.csv'\n", 207 | "input_file = open(fileName, 'r')\n", 208 | "i = 1\n", 209 | "for line in input_file:\n", 210 | " wineid = i\n", 211 | " row = line.split(';')\n", 212 | " \n", 213 | " query = \"INSERT INTO wines (wineid, fixedAcidity, volatileAcidity, citricAcid, sugar, \\\n", 214 | " chlorides, freeSulfur, totalSulfur, density, ph, \\\n", 215 | " sulphates, alcohol, quality)\"\n", 216 | " query = query + \" VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)\"\n", 217 | " session.execute(query, (wineid, float(row[0]), float(row[1]), float(row[2]), float(row[3]), float(row[4]), float(row[5]), float(row[6]), float(row[7]), float(row[8]), float(row[9]), float(row[10]), float(row[11])))\n", 218 | " i = i + 1\n", 219 | "\n", 220 | "fileName = 'data/winequality-white.csv'\n", 221 | "input_file = open(fileName, 'r')\n", 222 | "\n", 223 | "for line in input_file:\n", 224 | " wineid = i\n", 225 | " row = line.split(';')\n", 226 | " \n", 227 | " query = \"INSERT INTO wines (wineid, fixedAcidity, volatileAcidity, citricAcid, sugar, \\\n", 228 | " chlorides, freeSulfur, totalSulfur, density, ph, \\\n", 229 | " sulphates, alcohol, quality)\"\n", 230 | " query = query + \" VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)\"\n", 231 | " session.execute(query, (wineid, float(row[0]), float(row[1]), float(row[2]), float(row[3]), float(row[4]), float(row[5]), float(row[6]), float(row[7]), float(row[8]), float(row[9]), float(row[10]), float(row[11])))\n", 232 | " i = i + 1\n", 233 | " " 234 | ] 235 | }, 236 | { 237 | "cell_type": "markdown", 238 | "metadata": {}, 239 | "source": [ 240 | "## Machine Learning with Apache Cassandra and Apache Spark\n", 241 | "" 242 | ] 243 | }, 244 | { 245 | "cell_type": "markdown", 246 | "metadata": {}, 247 | "source": [ 248 | "#### Create a spark session that is connected to the database. From there load each table into a Spark Dataframe and take a count of the number of rows in each." 249 | ] 250 | }, 251 | { 252 | "cell_type": "code", 253 | "execution_count": null, 254 | "metadata": {}, 255 | "outputs": [], 256 | "source": [ 257 | "spark = SparkSession.builder.appName('demo').master(\"local\").getOrCreate()\n", 258 | "\n", 259 | "\n", 260 | "wineDF = spark.read.format(\"org.apache.spark.sql.cassandra\").options(table=\"wines\", keyspace=\"accelerate\").load()\n", 261 | "\n", 262 | "print (\"Table Wine Row Count: \")\n", 263 | "print (wineDF.count())" 264 | ] 265 | }, 266 | { 267 | "cell_type": "code", 268 | "execution_count": null, 269 | "metadata": {}, 270 | "outputs": [], 271 | "source": [ 272 | "showDF(wineDF)" 273 | ] 274 | }, 275 | { 276 | "cell_type": "markdown", 277 | "metadata": {}, 278 | "source": [ 279 | "#### Let's filter out only wines that have been rated 6.0 or higher and create a new dataframe with that information " 280 | ] 281 | }, 282 | { 283 | "cell_type": "code", 284 | "execution_count": null, 285 | "metadata": {}, 286 | "outputs": [], 287 | "source": [ 288 | "wine6DF = wineDF.filter(\"quality > 5\")\n", 289 | "showDF(wine6DF)" 290 | ] 291 | }, 292 | { 293 | "cell_type": "markdown", 294 | "metadata": {}, 295 | "source": [ 296 | "#### Create Vector with all elements of the wine " 297 | ] 298 | }, 299 | { 300 | "cell_type": "code", 301 | "execution_count": null, 302 | "metadata": {}, 303 | "outputs": [], 304 | "source": [ 305 | "assembler = VectorAssembler(\n", 306 | " inputCols=['alcohol', 'chlorides', 'citricacid', 'density', 'fixedacidity', 'ph', 'freesulfur', 'sugar', 'sulphates', 'totalsulfur', 'volatileacidity'],\n", 307 | " outputCol='features')\n", 308 | "\n", 309 | "trainingData = assembler.transform(wine6DF)\n", 310 | "\n", 311 | "labelIndexer = StringIndexer(inputCol=\"quality\", outputCol=\"label\", handleInvalid='keep')\n", 312 | "trainingData1 = labelIndexer.fit(trainingData).transform(trainingData)\n", 313 | "\n", 314 | "showDF(trainingData1)\n", 315 | "print(trainingData1.count())" 316 | ] 317 | }, 318 | { 319 | "cell_type": "markdown", 320 | "metadata": {}, 321 | "source": [ 322 | "### We will be training a model with Random Forest, and because of this we need to split up our dataset in to a training and test set. Will split 80/20. " 323 | ] 324 | }, 325 | { 326 | "cell_type": "code", 327 | "execution_count": null, 328 | "metadata": {}, 329 | "outputs": [], 330 | "source": [ 331 | "# Split the data into train and test\n", 332 | "splits = trainingData1.randomSplit([0.8, 0.2], 1234)\n", 333 | "train = splits[0]\n", 334 | "test = splits[1]\n", 335 | "\n", 336 | "print (\"Train Dataframe Row Count: \")\n", 337 | "print (train.count())\n", 338 | "print (\"Test Datafram Row Count: \")\n", 339 | "print (test.count())" 340 | ] 341 | }, 342 | { 343 | "cell_type": "code", 344 | "execution_count": null, 345 | "metadata": {}, 346 | "outputs": [], 347 | "source": [ 348 | "rf = RandomForestClassifier(labelCol=\"label\", featuresCol=\"features\", numTrees=10)\n", 349 | "\n", 350 | "model = rf.fit(train)\n", 351 | "\n", 352 | "predictions = model.transform(test)\n", 353 | "#predictions.show()\n", 354 | "print (predictions.count())\n", 355 | "showDF(predictions)" 356 | ] 357 | }, 358 | { 359 | "cell_type": "code", 360 | "execution_count": null, 361 | "metadata": {}, 362 | "outputs": [], 363 | "source": [ 364 | "showDF(predictions.select(\"quality\", \"label\", \"prediction\", \"probability\"))" 365 | ] 366 | }, 367 | { 368 | "cell_type": "markdown", 369 | "metadata": {}, 370 | "source": [ 371 | "### We can now use the MutliclassClassifciationEvaluator to evalute the accurancy of our predictions. " 372 | ] 373 | }, 374 | { 375 | "cell_type": "code", 376 | "execution_count": null, 377 | "metadata": {}, 378 | "outputs": [], 379 | "source": [ 380 | "# compute accuracy on the test set\n", 381 | "evaluator = MulticlassClassificationEvaluator(labelCol=\"label\", predictionCol=\"prediction\",\n", 382 | " metricName=\"accuracy\")\n", 383 | "accuracy = evaluator.evaluate(predictions)\n", 384 | "print(\"Test set accuracy = \" + str(accuracy))" 385 | ] 386 | }, 387 | { 388 | "cell_type": "code", 389 | "execution_count": null, 390 | "metadata": { 391 | "scrolled": true 392 | }, 393 | "outputs": [], 394 | "source": [ 395 | "session.execute(\"\"\"drop table wines\"\"\")" 396 | ] 397 | } 398 | ], 399 | "metadata": { 400 | "kernelspec": { 401 | "display_name": "Python 3", 402 | "language": "python", 403 | "name": "python3" 404 | }, 405 | "language_info": { 406 | "codemirror_mode": { 407 | "name": "ipython", 408 | "version": 3 409 | }, 410 | "file_extension": ".py", 411 | "mimetype": "text/x-python", 412 | "name": "python", 413 | "nbconvert_exporter": "python", 414 | "pygments_lexer": "ipython3", 415 | "version": "3.7.3" 416 | } 417 | }, 418 | "nbformat": 4, 419 | "nbformat_minor": 2 420 | } 421 | -------------------------------------------------------------------------------- /jupyter/Naivebayes.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "# Demo 2: Naive Bayes and DataStax Analytics\n", 8 | "------\n", 9 | "\n", 10 | "\n", 11 | "\n", 12 | "#### Dataset: https://archive.ics.uci.edu/ml/datasets/Wine+Quality" 13 | ] 14 | }, 15 | { 16 | "cell_type": "markdown", 17 | "metadata": {}, 18 | "source": [ 19 | "## What are we trying to learn from this dataset? \n", 20 | "\n", 21 | "# QUESTION: Can Naive Bayes be used to classify a wine’s rating score by its attributes?" 22 | ] 23 | }, 24 | { 25 | "cell_type": "code", 26 | "execution_count": null, 27 | "metadata": {}, 28 | "outputs": [], 29 | "source": [ 30 | "%matplotlib inline\n", 31 | "import matplotlib.pyplot as plt" 32 | ] 33 | }, 34 | { 35 | "cell_type": "code", 36 | "execution_count": null, 37 | "metadata": {}, 38 | "outputs": [], 39 | "source": [ 40 | "import pandas\n", 41 | "import cassandra\n", 42 | "import pyspark\n", 43 | "import re\n", 44 | "import os\n", 45 | "import random\n", 46 | "from random import randint, randrange\n", 47 | "import matplotlib.pyplot as plt\n", 48 | "from IPython.display import display, Markdown\n", 49 | "from pyspark.sql import SparkSession\n", 50 | "from pyspark.ml.classification import NaiveBayes\n", 51 | "from pyspark.ml.evaluation import MulticlassClassificationEvaluator\n", 52 | "from pyspark.ml.linalg import Vectors\n", 53 | "from pyspark.ml.feature import VectorAssembler\n", 54 | "from pyspark.ml.feature import StringIndexer" 55 | ] 56 | }, 57 | { 58 | "cell_type": "markdown", 59 | "metadata": {}, 60 | "source": [ 61 | "#### Helper function to have nicer formatting of Spark DataFrames" 62 | ] 63 | }, 64 | { 65 | "cell_type": "code", 66 | "execution_count": null, 67 | "metadata": {}, 68 | "outputs": [], 69 | "source": [ 70 | "#Helper for pretty formatting for Spark DataFrames\n", 71 | "def showDF(df, limitRows = 5, truncate = True):\n", 72 | " if(truncate):\n", 73 | " pandas.set_option('display.max_colwidth', 50)\n", 74 | " else:\n", 75 | " pandas.set_option('display.max_colwidth', -1)\n", 76 | " pandas.set_option('display.max_rows', limitRows)\n", 77 | " display(df.limit(limitRows).toPandas())\n", 78 | " pandas.reset_option('display.max_rows')" 79 | ] 80 | }, 81 | { 82 | "cell_type": "markdown", 83 | "metadata": {}, 84 | "source": [ 85 | "" 86 | ] 87 | }, 88 | { 89 | "cell_type": "markdown", 90 | "metadata": {}, 91 | "source": [ 92 | "## Creating Tables and Loading Tables" 93 | ] 94 | }, 95 | { 96 | "cell_type": "markdown", 97 | "metadata": {}, 98 | "source": [ 99 | "### Connect to Cassandra" 100 | ] 101 | }, 102 | { 103 | "cell_type": "code", 104 | "execution_count": null, 105 | "metadata": {}, 106 | "outputs": [], 107 | "source": [ 108 | "from cassandra.cluster import Cluster\n", 109 | "\n", 110 | "cluster = Cluster(['dse'])\n", 111 | "session = cluster.connect()" 112 | ] 113 | }, 114 | { 115 | "cell_type": "markdown", 116 | "metadata": {}, 117 | "source": [ 118 | "### Create Demo Keyspace " 119 | ] 120 | }, 121 | { 122 | "cell_type": "code", 123 | "execution_count": null, 124 | "metadata": { 125 | "scrolled": true 126 | }, 127 | "outputs": [], 128 | "source": [ 129 | "session.execute(\"\"\"\n", 130 | " CREATE KEYSPACE IF NOT EXISTS accelerate \n", 131 | " WITH REPLICATION = \n", 132 | " { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }\"\"\"\n", 133 | ")" 134 | ] 135 | }, 136 | { 137 | "cell_type": "markdown", 138 | "metadata": {}, 139 | "source": [ 140 | "### Set keyspace " 141 | ] 142 | }, 143 | { 144 | "cell_type": "code", 145 | "execution_count": null, 146 | "metadata": {}, 147 | "outputs": [], 148 | "source": [ 149 | "session.set_keyspace('accelerate')" 150 | ] 151 | }, 152 | { 153 | "cell_type": "markdown", 154 | "metadata": {}, 155 | "source": [ 156 | "### Create table called `wines`. Our PRIMARY will be a unique key (wineid) we generate for each row. This will have two datasets \"white\" and \"red\"" 157 | ] 158 | }, 159 | { 160 | "cell_type": "code", 161 | "execution_count": null, 162 | "metadata": {}, 163 | "outputs": [], 164 | "source": [ 165 | "query = \"CREATE TABLE IF NOT EXISTS wines \\\n", 166 | " (wineid int, fixedAcidity float, volatileAcidity float, citricAcid float, sugar float, \\\n", 167 | " chlorides float, freeSulfur float, totalSulfur float, density float, ph float, \\\n", 168 | " sulphates float, alcohol float, quality float, \\\n", 169 | " PRIMARY KEY (wineid))\"\n", 170 | "session.execute(query)" 171 | ] 172 | }, 173 | { 174 | "cell_type": "markdown", 175 | "metadata": {}, 176 | "source": [ 177 | "### What do these of these 12 columns represent: \n", 178 | "\n", 179 | "* **Fixed acidity**\n", 180 | "* **Volatile acidity**\n", 181 | "* **Citric Acid**\n", 182 | "* **Residual Sugar** \n", 183 | "* **Chlorides**\n", 184 | "* **Free sulfur dioxide** \n", 185 | "* **Total sulfur dioxide**\n", 186 | "* **Density** \n", 187 | "* **pH**\n", 188 | "* **Sulphates**\n", 189 | "* **Alcohol**\n", 190 | "* **Quality**" 191 | ] 192 | }, 193 | { 194 | "cell_type": "markdown", 195 | "metadata": {}, 196 | "source": [ 197 | "### Load 2 Wine Dataset -- White and Red\n", 198 | "" 199 | ] 200 | }, 201 | { 202 | "cell_type": "markdown", 203 | "metadata": {}, 204 | "source": [ 205 | "### Load Wine datasets from CSV file (winequality-red.csv winequality-white.csv)\n", 206 | "* No clean up was requried! How nice :)\n", 207 | "\n", 208 | "#### Insert all the Wine Data into the DSE table `wines`" 209 | ] 210 | }, 211 | { 212 | "cell_type": "code", 213 | "execution_count": null, 214 | "metadata": {}, 215 | "outputs": [], 216 | "source": [ 217 | "fileName = 'data/winequality-red.csv'\n", 218 | "input_file = open(fileName, 'r')\n", 219 | "i = 1\n", 220 | "for line in input_file:\n", 221 | " wineid = i\n", 222 | " row = line.split(';')\n", 223 | " \n", 224 | " query = \"INSERT INTO wines (wineid, fixedAcidity, volatileAcidity, citricAcid, sugar, \\\n", 225 | " chlorides, freeSulfur, totalSulfur, density, ph, \\\n", 226 | " sulphates, alcohol, quality)\"\n", 227 | " query = query + \" VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)\"\n", 228 | " session.execute(query, (wineid, float(row[0]), float(row[1]), float(row[2]), float(row[3]), float(row[4]), float(row[5]), float(row[6]), float(row[7]), float(row[8]), float(row[9]), float(row[10]), float(row[11])))\n", 229 | " i = i + 1\n", 230 | "\n", 231 | "fileName = 'data/winequality-white.csv'\n", 232 | "input_file = open(fileName, 'r')\n", 233 | "\n", 234 | "for line in input_file:\n", 235 | " wineid = i\n", 236 | " row = line.split(';')\n", 237 | " \n", 238 | " query = \"INSERT INTO wines (wineid, fixedAcidity, volatileAcidity, citricAcid, sugar, \\\n", 239 | " chlorides, freeSulfur, totalSulfur, density, ph, \\\n", 240 | " sulphates, alcohol, quality)\"\n", 241 | " query = query + \" VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)\"\n", 242 | " session.execute(query, (wineid, float(row[0]), float(row[1]), float(row[2]), float(row[3]), float(row[4]), float(row[5]), float(row[6]), float(row[7]), float(row[8]), float(row[9]), float(row[10]), float(row[11])))\n", 243 | " i = i + 1\n", 244 | " " 245 | ] 246 | }, 247 | { 248 | "cell_type": "markdown", 249 | "metadata": {}, 250 | "source": [ 251 | "## Machine Learning with Apache Cassandra & Apache Spark\n", 252 | "" 253 | ] 254 | }, 255 | { 256 | "cell_type": "markdown", 257 | "metadata": {}, 258 | "source": [ 259 | "#### Create a spark session that is connected to the database. From there load each table into a Spark Dataframe and take a count of the number of rows in each." 260 | ] 261 | }, 262 | { 263 | "cell_type": "code", 264 | "execution_count": null, 265 | "metadata": {}, 266 | "outputs": [], 267 | "source": [ 268 | "spark = SparkSession.builder.appName('demo').master(\"local\").getOrCreate()\n", 269 | "\n", 270 | "wineDF = spark.read.format(\"org.apache.spark.sql.cassandra\").options(table=\"wines\", keyspace=\"accelerate\").load()\n", 271 | "\n", 272 | "print (\"Table Wine Row Count: \")\n", 273 | "print (wineDF.count())" 274 | ] 275 | }, 276 | { 277 | "cell_type": "code", 278 | "execution_count": null, 279 | "metadata": {}, 280 | "outputs": [], 281 | "source": [ 282 | "showDF(wineDF)" 283 | ] 284 | }, 285 | { 286 | "cell_type": "markdown", 287 | "metadata": {}, 288 | "source": [ 289 | "#### Let's filter out only wines that have been rated 6.0 or higher and create a new dataframe with that information " 290 | ] 291 | }, 292 | { 293 | "cell_type": "code", 294 | "execution_count": null, 295 | "metadata": {}, 296 | "outputs": [], 297 | "source": [ 298 | "wine6DF = wineDF.filter(\"quality > 5\")\n", 299 | "showDF(wine6DF)" 300 | ] 301 | }, 302 | { 303 | "cell_type": "markdown", 304 | "metadata": {}, 305 | "source": [ 306 | "#### Create Vector with all elements of the wine " 307 | ] 308 | }, 309 | { 310 | "cell_type": "code", 311 | "execution_count": null, 312 | "metadata": {}, 313 | "outputs": [], 314 | "source": [ 315 | "assembler = VectorAssembler(\n", 316 | " inputCols=['alcohol', 'chlorides', 'citricacid', 'density', 'fixedacidity', 'ph', 'freesulfur', 'sugar', 'sulphates', 'totalsulfur', 'volatileacidity'],\n", 317 | " outputCol='features')\n", 318 | "\n", 319 | "trainingData = assembler.transform(wine6DF)\n", 320 | "\n", 321 | "labelIndexer = StringIndexer(inputCol=\"quality\", outputCol=\"label\", handleInvalid='keep')\n", 322 | "trainingData1 = labelIndexer.fit(trainingData).transform(trainingData)\n", 323 | "\n", 324 | "showDF(trainingData1)\n", 325 | "print(trainingData1.count())" 326 | ] 327 | }, 328 | { 329 | "cell_type": "markdown", 330 | "metadata": {}, 331 | "source": [ 332 | "We need to split up our dataset in to a training and test set. Will split 80/20. " 333 | ] 334 | }, 335 | { 336 | "cell_type": "code", 337 | "execution_count": null, 338 | "metadata": {}, 339 | "outputs": [], 340 | "source": [ 341 | "# Split the data into train and test\n", 342 | "splits = trainingData1.randomSplit([0.8, 0.2], 1234)\n", 343 | "train = splits[0]\n", 344 | "test = splits[1]\n", 345 | "\n", 346 | "print (\"Train Dataframe Row Count: \")\n", 347 | "print (train.count())\n", 348 | "print (\"Test Dataframe Row Count: \")\n", 349 | "print (test.count())" 350 | ] 351 | }, 352 | { 353 | "cell_type": "markdown", 354 | "metadata": {}, 355 | "source": [ 356 | "### Now it's time to to use NaiveBayes. We will train the model, then use that model with out testing data to get our predictions. \n", 357 | "https://spark.apache.org/docs/2.2.0/ml-classification-regression.html#naive-bayes" 358 | ] 359 | }, 360 | { 361 | "cell_type": "code", 362 | "execution_count": null, 363 | "metadata": {}, 364 | "outputs": [], 365 | "source": [ 366 | "nb = NaiveBayes(smoothing=1.0, modelType=\"multinomial\")\n", 367 | "\n", 368 | "# train the model\n", 369 | "model = nb.fit(train)\n", 370 | "\n", 371 | "predictions = model.transform(test)\n", 372 | "#predictions.show()\n", 373 | "print (predictions.count())\n", 374 | "showDF(predictions)" 375 | ] 376 | }, 377 | { 378 | "cell_type": "code", 379 | "execution_count": null, 380 | "metadata": {}, 381 | "outputs": [], 382 | "source": [ 383 | "showDF(predictions.select(\"quality\", \"label\", \"prediction\", \"probability\"))" 384 | ] 385 | }, 386 | { 387 | "cell_type": "markdown", 388 | "metadata": {}, 389 | "source": [ 390 | "### We can now use the MutliclassClassifciationEvaluator to evalute the accurancy of our predictions. " 391 | ] 392 | }, 393 | { 394 | "cell_type": "code", 395 | "execution_count": null, 396 | "metadata": {}, 397 | "outputs": [], 398 | "source": [ 399 | "# compute accuracy on the test set\n", 400 | "evaluator = MulticlassClassificationEvaluator(labelCol=\"label\", predictionCol=\"prediction\",\n", 401 | " metricName=\"accuracy\")\n", 402 | "accuracy = evaluator.evaluate(predictions)\n", 403 | "print(\"Test set accuracy = \" + str(accuracy))" 404 | ] 405 | } 406 | ], 407 | "metadata": { 408 | "kernelspec": { 409 | "display_name": "Python 3", 410 | "language": "python", 411 | "name": "python3" 412 | }, 413 | "language_info": { 414 | "codemirror_mode": { 415 | "name": "ipython", 416 | "version": 3 417 | }, 418 | "file_extension": ".py", 419 | "mimetype": "text/x-python", 420 | "name": "python", 421 | "nbconvert_exporter": "python", 422 | "pygments_lexer": "ipython3", 423 | "version": "3.7.3" 424 | } 425 | }, 426 | "nbformat": 4, 427 | "nbformat_minor": 2 428 | } 429 | -------------------------------------------------------------------------------- /jupyter/kmeans.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "# Demo 1: K-Means and DataStax Analytics\n", 8 | "------\n", 9 | "\n", 10 | "\n", 11 | "\n", 12 | "#### Dataset: https://archive.ics.uci.edu/ml/datasets/Facebook+Live+Sellers+in+Thailand" 13 | ] 14 | }, 15 | { 16 | "cell_type": "markdown", 17 | "metadata": {}, 18 | "source": [ 19 | "## What are we trying to learn from this dataset? \n", 20 | "\n", 21 | "# QUESTION: Can K-Means be used to do social media analysis, can we group together different types of media by the reaction they received?\n" 22 | ] 23 | }, 24 | { 25 | "cell_type": "code", 26 | "execution_count": null, 27 | "metadata": {}, 28 | "outputs": [], 29 | "source": [ 30 | "%matplotlib inline\n", 31 | "import matplotlib.pyplot as plt" 32 | ] 33 | }, 34 | { 35 | "cell_type": "code", 36 | "execution_count": null, 37 | "metadata": {}, 38 | "outputs": [], 39 | "source": [ 40 | "import pandas\n", 41 | "import cassandra\n", 42 | "import pyspark\n", 43 | "import re\n", 44 | "import os\n", 45 | "import random\n", 46 | "from random import randint, randrange\n", 47 | "import matplotlib.pyplot as plt\n", 48 | "from IPython.display import display, Markdown\n", 49 | "from pyspark.sql import SparkSession\n", 50 | "from pyspark.ml.linalg import Vectors\n", 51 | "from pyspark.ml.feature import VectorAssembler\n", 52 | "from pyspark.ml.feature import StringIndexer\n", 53 | "from pyspark.ml.clustering import KMeans" 54 | ] 55 | }, 56 | { 57 | "cell_type": "markdown", 58 | "metadata": {}, 59 | "source": [ 60 | "#### Helper function to have nicer formatting of Spark DataFrames" 61 | ] 62 | }, 63 | { 64 | "cell_type": "code", 65 | "execution_count": null, 66 | "metadata": {}, 67 | "outputs": [], 68 | "source": [ 69 | "#Helper for pretty formatting for Spark DataFrames\n", 70 | "def showDF(df, limitRows = 5, truncate = True):\n", 71 | " if(truncate):\n", 72 | " pandas.set_option('display.max_colwidth', 50)\n", 73 | " else:\n", 74 | " pandas.set_option('display.max_colwidth', -1)\n", 75 | " pandas.set_option('display.max_rows', limitRows)\n", 76 | " display(df.limit(limitRows).toPandas())\n", 77 | " pandas.reset_option('display.max_rows')" 78 | ] 79 | }, 80 | { 81 | "cell_type": "markdown", 82 | "metadata": {}, 83 | "source": [ 84 | "" 85 | ] 86 | }, 87 | { 88 | "cell_type": "markdown", 89 | "metadata": {}, 90 | "source": [ 91 | "## Creating Tables and Loading Tables" 92 | ] 93 | }, 94 | { 95 | "cell_type": "markdown", 96 | "metadata": {}, 97 | "source": [ 98 | "### Connect to Cassandra" 99 | ] 100 | }, 101 | { 102 | "cell_type": "code", 103 | "execution_count": null, 104 | "metadata": {}, 105 | "outputs": [], 106 | "source": [ 107 | "from cassandra.cluster import Cluster\n", 108 | "\n", 109 | "cluster = Cluster(['dse'])\n", 110 | "session = cluster.connect()" 111 | ] 112 | }, 113 | { 114 | "cell_type": "markdown", 115 | "metadata": {}, 116 | "source": [ 117 | "### Create Demo Keyspace " 118 | ] 119 | }, 120 | { 121 | "cell_type": "code", 122 | "execution_count": null, 123 | "metadata": {}, 124 | "outputs": [], 125 | "source": [ 126 | "session.execute(\"\"\"\n", 127 | " CREATE KEYSPACE IF NOT EXISTS accelerate \n", 128 | " WITH REPLICATION = \n", 129 | " { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }\"\"\"\n", 130 | ")" 131 | ] 132 | }, 133 | { 134 | "cell_type": "markdown", 135 | "metadata": {}, 136 | "source": [ 137 | "### Set keyspace " 138 | ] 139 | }, 140 | { 141 | "cell_type": "code", 142 | "execution_count": null, 143 | "metadata": {}, 144 | "outputs": [], 145 | "source": [ 146 | "session.set_keyspace('accelerate')" 147 | ] 148 | }, 149 | { 150 | "cell_type": "markdown", 151 | "metadata": {}, 152 | "source": [ 153 | "### Create table called `socialMedia`. Our PRIMARY will be a unique key (status_id) we generate for each row. " 154 | ] 155 | }, 156 | { 157 | "cell_type": "code", 158 | "execution_count": null, 159 | "metadata": {}, 160 | "outputs": [], 161 | "source": [ 162 | "query = \"CREATE TABLE IF NOT EXISTS socialMedia \\\n", 163 | " (status_id int, social_type text, num_reactions int,\\\n", 164 | " num_comments int, num_shares int, num_likes int, num_loves int,\\\n", 165 | " num_wows int, num_hahas int, num_sads int, num_angrys int, \\\n", 166 | " PRIMARY KEY (status_id))\"\n", 167 | "session.execute(query)" 168 | ] 169 | }, 170 | { 171 | "cell_type": "markdown", 172 | "metadata": {}, 173 | "source": [ 174 | "### What do these of these 11 columns represent: \n", 175 | "\n", 176 | "* **Status_id**: Unique key created for each row\n", 177 | "\n", 178 | "* **Num Reactions**: \n", 179 | "\n", 180 | "* **Num Comments**:\n", 181 | "\n", 182 | "* **Num Shares**:\n", 183 | "\n", 184 | "* **Num Likes**:\n", 185 | "\n", 186 | "* **Num Loves**:\n", 187 | "\n", 188 | "* **Num Wows**:\n", 189 | "\n", 190 | "* **Num Hahas**:\n", 191 | "\n", 192 | "* **Num Sads**:\n", 193 | "\n", 194 | "* **Num Angrys**:\n", 195 | "\n", 196 | "* **Social Type**: Picture or Video\n" 197 | ] 198 | }, 199 | { 200 | "cell_type": "markdown", 201 | "metadata": {}, 202 | "source": [ 203 | "### Load Social Media Dataset\n", 204 | "" 205 | ] 206 | }, 207 | { 208 | "cell_type": "markdown", 209 | "metadata": {}, 210 | "source": [ 211 | "### Load dataset from CSV file (socialMedia.csv)\n", 212 | "\n", 213 | "#### Insert all the Data into the Apache Cassandra table `socialmedia`" 214 | ] 215 | }, 216 | { 217 | "cell_type": "code", 218 | "execution_count": null, 219 | "metadata": {}, 220 | "outputs": [], 221 | "source": [ 222 | "fileName = 'data/socialMedia.csv'\n", 223 | "input_file = open(fileName, 'r')\n", 224 | "i = 1\n", 225 | "for line in input_file:\n", 226 | " statusId = i\n", 227 | " row = line.split(',')\n", 228 | " \n", 229 | " if row[0] != \"photo\" and row[0] != \"video\":\n", 230 | " continue\n", 231 | "\n", 232 | " query = \"INSERT INTO socialmedia (status_id, social_type, num_reactions, num_comments, num_shares,\\\n", 233 | " num_likes, num_loves, num_wows, num_hahas, num_sads, num_angrys)\"\n", 234 | " query = query + \" VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)\"\n", 235 | " session.execute(query, (statusId, row[0], int(row[1]), int(row[2]), int(row[3]), int(row[4]), int(row[5]), int(row[6]), int(row[7]), int(row[8]), int(row[9])))\n", 236 | " i = i + 1\n", 237 | " " 238 | ] 239 | }, 240 | { 241 | "cell_type": "markdown", 242 | "metadata": {}, 243 | "source": [ 244 | "## Machine Learning with Apache Spark\n", 245 | "" 246 | ] 247 | }, 248 | { 249 | "cell_type": "markdown", 250 | "metadata": {}, 251 | "source": [ 252 | "#### Create a spark session that is connected to DSE. From there load each table into a Spark Dataframe and take a count of the number of rows in each." 253 | ] 254 | }, 255 | { 256 | "cell_type": "code", 257 | "execution_count": null, 258 | "metadata": {}, 259 | "outputs": [], 260 | "source": [ 261 | "spark = SparkSession.builder.appName('demo').master(\"local\").getOrCreate()\n", 262 | "\n", 263 | "\n", 264 | "socialDF = spark.read.format(\"org.apache.spark.sql.cassandra\").options(table=\"socialmedia\", keyspace=\"accelerate\").load()\n", 265 | "\n", 266 | "print (\"Table Row Count: \")\n", 267 | "print (socialDF.count())" 268 | ] 269 | }, 270 | { 271 | "cell_type": "code", 272 | "execution_count": null, 273 | "metadata": {}, 274 | "outputs": [], 275 | "source": [ 276 | "showDF(socialDF)" 277 | ] 278 | }, 279 | { 280 | "cell_type": "markdown", 281 | "metadata": {}, 282 | "source": [ 283 | "#### When working with `STRING` data types you need to turn those `STRING` types into `FLOAT` types. Creating labels that K-MEANS and Apahce SPARK can understand." 284 | ] 285 | }, 286 | { 287 | "cell_type": "code", 288 | "execution_count": null, 289 | "metadata": {}, 290 | "outputs": [], 291 | "source": [ 292 | "labelIndexer = StringIndexer(inputCol=\"social_type\", outputCol=\"label\", handleInvalid='keep')\n", 293 | "training = labelIndexer.fit(socialDF).transform(socialDF)\n", 294 | "\n", 295 | "showDF(training)\n" 296 | ] 297 | }, 298 | { 299 | "cell_type": "code", 300 | "execution_count": null, 301 | "metadata": {}, 302 | "outputs": [], 303 | "source": [ 304 | "showDF(training.select(\"social_type\",\"label\"))" 305 | ] 306 | }, 307 | { 308 | "cell_type": "code", 309 | "execution_count": null, 310 | "metadata": {}, 311 | "outputs": [], 312 | "source": [ 313 | "training.groupBy('social_type').count().show()" 314 | ] 315 | }, 316 | { 317 | "cell_type": "markdown", 318 | "metadata": {}, 319 | "source": [ 320 | "## Let's visualize this data with a scatter plot \n", 321 | "### The x axis will be number of likes \n", 322 | "### The y axis will be number of comments\n", 323 | "### The color of the dot will be assigned based on its \"cluster\" Photo or Video\n", 324 | "\n", 325 | "Note: These attributes are what might be a strong attributes to finding clusters (Photo - Video)\n", 326 | "Note 1: Must move to a Pandas dataframe to do this visualization (be aware! This can't always be done as is, depends on your data size)" 327 | ] 328 | }, 329 | { 330 | "cell_type": "code", 331 | "execution_count": null, 332 | "metadata": {}, 333 | "outputs": [], 334 | "source": [ 335 | "smPanda = training.toPandas()\n", 336 | "smPanda.plot.scatter(x = 'num_likes', y = 'num_comments', c= 'label', figsize=(12,8), colormap='viridis')" 337 | ] 338 | }, 339 | { 340 | "cell_type": "markdown", 341 | "metadata": {}, 342 | "source": [ 343 | "### Two clusters here Yellow = Video and Purple = Pictures\n", 344 | "\n", 345 | "From what we can see from these two attributes Videos get less likes but more comments. Pictures get less comments but more likes. " 346 | ] 347 | }, 348 | { 349 | "cell_type": "markdown", 350 | "metadata": {}, 351 | "source": [ 352 | "## Let's see if Kmeans can give us the same clustering\n", 353 | "\n", 354 | "## K-means clustering is a simple unsupervised learning algorithm that is used to solve clustering problems. Kmeans is very simple, but very powerful even on large datasets. It requires that all the input columns be vectorized. \n", 355 | "\n", 356 | "https://spark.apache.org/docs/latest/ml-features.html#vectorassembler" 357 | ] 358 | }, 359 | { 360 | "cell_type": "code", 361 | "execution_count": null, 362 | "metadata": {}, 363 | "outputs": [], 364 | "source": [ 365 | "assembler = VectorAssembler(\n", 366 | " inputCols=[ 'num_likes', 'num_comments'],\n", 367 | " outputCol='features')\n", 368 | "\n", 369 | "trainingData = assembler.transform(training)" 370 | ] 371 | }, 372 | { 373 | "cell_type": "markdown", 374 | "metadata": {}, 375 | "source": [ 376 | "### We need to set the K for KMeans which we will set at 2. One of the downsides of unsupervised learning is that we normally will not have clusteres predefinded (like we do in this case). Kmeans will happily split the data into as many clusters as you set. \n", 377 | "\n", 378 | "#### First we will generate the model and then make predictions based on that model " 379 | ] 380 | }, 381 | { 382 | "cell_type": "code", 383 | "execution_count": null, 384 | "metadata": {}, 385 | "outputs": [], 386 | "source": [ 387 | "kmeans = KMeans().setK(2).setSeed(1)\n", 388 | "model = kmeans.fit(trainingData)\n", 389 | "\n", 390 | "# Make predictions\n", 391 | "predictions = model.transform(trainingData)\n", 392 | "\n", 393 | "showDF(predictions)" 394 | ] 395 | }, 396 | { 397 | "cell_type": "markdown", 398 | "metadata": {}, 399 | "source": [ 400 | "## In this case because we are actually preforming surpervised learnings (since we do have the cluster labels) we can do some comparisions to see if our predictions are correct. \n", 401 | "\n", 402 | "## In this case I am just taking a look at the counts for each group. " 403 | ] 404 | }, 405 | { 406 | "cell_type": "code", 407 | "execution_count": null, 408 | "metadata": {}, 409 | "outputs": [], 410 | "source": [ 411 | "predictions.groupBy('prediction').count().show()\n", 412 | "training.groupBy('social_type').count().show()" 413 | ] 414 | }, 415 | { 416 | "cell_type": "markdown", 417 | "metadata": {}, 418 | "source": [ 419 | "## Let's create another scatter plot to see if this lines up with our orignal scatter plot. \n", 420 | "\n", 421 | "## Everything is the same except now our dots will represent the color of the prediction (instead of the orginal cluster)" 422 | ] 423 | }, 424 | { 425 | "cell_type": "code", 426 | "execution_count": null, 427 | "metadata": {}, 428 | "outputs": [], 429 | "source": [ 430 | "car_df = predictions.toPandas()\n", 431 | "\n", 432 | "car_df.plot.scatter(x = 'num_likes', y = 'num_comments', c= 'prediction', figsize=(12,8), colormap='viridis')" 433 | ] 434 | }, 435 | { 436 | "cell_type": "markdown", 437 | "metadata": {}, 438 | "source": [ 439 | "### Videos are represented in yellow and pictures are represnted in purple." 440 | ] 441 | }, 442 | { 443 | "cell_type": "markdown", 444 | "metadata": {}, 445 | "source": [ 446 | "## KMeans struggles when you add many variables, so adding more variables is unlikely to help. " 447 | ] 448 | }, 449 | { 450 | "cell_type": "markdown", 451 | "metadata": {}, 452 | "source": [ 453 | "# Remember Data Science and analytics is an iterative process! It's a science! Hypothesis, test, analysis, and loop again! " 454 | ] 455 | } 456 | ], 457 | "metadata": { 458 | "kernelspec": { 459 | "display_name": "Python 3", 460 | "language": "python", 461 | "name": "python3" 462 | }, 463 | "language_info": { 464 | "codemirror_mode": { 465 | "name": "ipython", 466 | "version": 3 467 | }, 468 | "file_extension": ".py", 469 | "mimetype": "text/x-python", 470 | "name": "python", 471 | "nbconvert_exporter": "python", 472 | "pygments_lexer": "ipython3", 473 | "version": "3.7.3" 474 | } 475 | }, 476 | "nbformat": 4, 477 | "nbformat_minor": 2 478 | } 479 | -------------------------------------------------------------------------------- /jupyter/FP-Growth.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": {}, 6 | "source": [ 7 | "# Demo 4: FP-Growth and DataStax Analytics\n", 8 | "------\n", 9 | "\n", 10 | "\n", 11 | "\n", 12 | "#### Dataset: https://grouplens.org/datasets/movielens/" 13 | ] 14 | }, 15 | { 16 | "cell_type": "markdown", 17 | "metadata": {}, 18 | "source": [ 19 | "## What are we trying to learn from this dataset? \n", 20 | "\n", 21 | "# QUESTION: Can FP-Growth be used to find which movies to recommend to our users?\n" 22 | ] 23 | }, 24 | { 25 | "cell_type": "code", 26 | "execution_count": null, 27 | "metadata": {}, 28 | "outputs": [], 29 | "source": [ 30 | "%matplotlib inline\n", 31 | "import matplotlib.pyplot as plt" 32 | ] 33 | }, 34 | { 35 | "cell_type": "code", 36 | "execution_count": null, 37 | "metadata": {}, 38 | "outputs": [], 39 | "source": [ 40 | "import pandas\n", 41 | "import cassandra\n", 42 | "import pyspark\n", 43 | "import re\n", 44 | "import os\n", 45 | "import random\n", 46 | "import matplotlib.pyplot as plt\n", 47 | "from random import randint, randrange\n", 48 | "from IPython.display import display, Markdown\n", 49 | "from pyspark.sql import SparkSession\n", 50 | "from pyspark.ml.fpm import FPGrowth\n", 51 | "from pyspark.sql import Row\n", 52 | "from pyspark.sql.functions import collect_set\n", 53 | "from pyspark.ml.feature import IndexToString, StringIndexer, VectorAssembler\n", 54 | "from pyspark.ml.evaluation import MulticlassClassificationEvaluator" 55 | ] 56 | }, 57 | { 58 | "cell_type": "code", 59 | "execution_count": null, 60 | "metadata": {}, 61 | "outputs": [], 62 | "source": [ 63 | "#Helper for pretty formatting for Spark DataFrames\n", 64 | "def showDF(df, limitRows = 5, truncate = True):\n", 65 | " if(truncate):\n", 66 | " pandas.set_option('display.max_colwidth', 50)\n", 67 | " else:\n", 68 | " pandas.set_option('display.max_colwidth', -1)\n", 69 | " pandas.set_option('display.max_rows', limitRows)\n", 70 | " display(df.limit(limitRows).toPandas())\n", 71 | " pandas.reset_option('display.max_rows')" 72 | ] 73 | }, 74 | { 75 | "cell_type": "markdown", 76 | "metadata": {}, 77 | "source": [ 78 | "#### Helper function to have nicer formatting of Spark DataFrames" 79 | ] 80 | }, 81 | { 82 | "cell_type": "markdown", 83 | "metadata": {}, 84 | "source": [ 85 | "## Creating Tables and Loading Tables" 86 | ] 87 | }, 88 | { 89 | "cell_type": "markdown", 90 | "metadata": {}, 91 | "source": [ 92 | "" 93 | ] 94 | }, 95 | { 96 | "cell_type": "code", 97 | "execution_count": null, 98 | "metadata": {}, 99 | "outputs": [], 100 | "source": [ 101 | "from cassandra.cluster import Cluster\n", 102 | "\n", 103 | "cluster = Cluster(['dse'])\n", 104 | "session = cluster.connect()" 105 | ] 106 | }, 107 | { 108 | "cell_type": "markdown", 109 | "metadata": {}, 110 | "source": [ 111 | "### Create Demo Keyspace " 112 | ] 113 | }, 114 | { 115 | "cell_type": "code", 116 | "execution_count": null, 117 | "metadata": {}, 118 | "outputs": [], 119 | "source": [ 120 | "session.execute(\"\"\"\n", 121 | " CREATE KEYSPACE IF NOT EXISTS accelerate \n", 122 | " WITH REPLICATION = \n", 123 | " { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }\"\"\")" 124 | ] 125 | }, 126 | { 127 | "cell_type": "markdown", 128 | "metadata": {}, 129 | "source": [ 130 | "### Set keyspace " 131 | ] 132 | }, 133 | { 134 | "cell_type": "code", 135 | "execution_count": null, 136 | "metadata": {}, 137 | "outputs": [], 138 | "source": [ 139 | "session.set_keyspace('accelerate')" 140 | ] 141 | }, 142 | { 143 | "cell_type": "markdown", 144 | "metadata": {}, 145 | "source": [ 146 | "### Create table called `movies`. Our PRIMARY will be a unique key (movieid) " 147 | ] 148 | }, 149 | { 150 | "cell_type": "code", 151 | "execution_count": null, 152 | "metadata": {}, 153 | "outputs": [], 154 | "source": [ 155 | "query = \"CREATE TABLE IF NOT EXISTS movies \\\n", 156 | " (movieid int, title text, genres text, \\\n", 157 | " PRIMARY KEY (movieid))\"\n", 158 | "session.execute(query)" 159 | ] 160 | }, 161 | { 162 | "cell_type": "markdown", 163 | "metadata": {}, 164 | "source": [ 165 | "### Create table called `movieRatings`. Our PRIMARY key will be a compositite key (userid, movieid)." 166 | ] 167 | }, 168 | { 169 | "cell_type": "code", 170 | "execution_count": null, 171 | "metadata": {}, 172 | "outputs": [], 173 | "source": [ 174 | "query = \"CREATE TABLE IF NOT EXISTS movieratings \\\n", 175 | " (userid int, movieid int, rating float, timestamp text, \\\n", 176 | " PRIMARY KEY (userid, movieid))\"\n", 177 | "session.execute(query)" 178 | ] 179 | }, 180 | { 181 | "cell_type": "markdown", 182 | "metadata": {}, 183 | "source": [ 184 | "## Movies\n", 185 | "\n", 186 | "* **Movieid**\n", 187 | "* **Title**\n", 188 | "* **Genres**\n", 189 | "\n", 190 | "## Movie Ratings Table\n", 191 | "### What do these of these 4 columns represent:\n", 192 | "\n", 193 | "* **UserId**\n", 194 | "* **MovieId**\n", 195 | "* **Rating**\n", 196 | "* **Timestamp**" 197 | ] 198 | }, 199 | { 200 | "cell_type": "markdown", 201 | "metadata": {}, 202 | "source": [ 203 | "### Load 2 Movie Dataset -- Movies and Movie Ratings Table\n", 204 | "" 205 | ] 206 | }, 207 | { 208 | "cell_type": "markdown", 209 | "metadata": {}, 210 | "source": [ 211 | "### Load Movie datasets from CSV file (rating_movies.csv, movies.csv)\n", 212 | "* No clean up was requried! How nice :)\n", 213 | "\n", 214 | "#### Insert all the Movie Data into the table `movies` and `movieratings`" 215 | ] 216 | }, 217 | { 218 | "cell_type": "code", 219 | "execution_count": null, 220 | "metadata": {}, 221 | "outputs": [], 222 | "source": [ 223 | "fileName = 'data/ratings.csv'\n", 224 | "input_file = open(fileName, 'r')\n", 225 | "\n", 226 | "for line in input_file:\n", 227 | " row = line.split(',')\n", 228 | " \n", 229 | " query = \"INSERT INTO movieratings (userid, movieid, rating, timestamp)\"\n", 230 | " query = query + \" VALUES (%s, %s, %s, %s)\"\n", 231 | " session.execute(query, (int(row[0]), int(row[1]), float(row[2]), row[3]))" 232 | ] 233 | }, 234 | { 235 | "cell_type": "code", 236 | "execution_count": null, 237 | "metadata": {}, 238 | "outputs": [], 239 | "source": [ 240 | "fileName = 'data/movies.csv'\n", 241 | "input_file = open(fileName, 'r')\n", 242 | "\n", 243 | "for line in input_file:\n", 244 | " row = line.split(',')\n", 245 | " \n", 246 | " query = \"INSERT INTO movies (movieid, title, genres)\"\n", 247 | " query = query + \" VALUES (%s, %s, %s)\"\n", 248 | " session.execute(query, (int(row[0]), row[1], row[2]))" 249 | ] 250 | }, 251 | { 252 | "cell_type": "markdown", 253 | "metadata": {}, 254 | "source": [ 255 | "## Machine Learning with Apache Spark\n", 256 | "" 257 | ] 258 | }, 259 | { 260 | "cell_type": "markdown", 261 | "metadata": {}, 262 | "source": [ 263 | "#### Create a spark session that is connected to cassandra. From there load each table into a Spark Dataframe and take a count of the number of rows in each." 264 | ] 265 | }, 266 | { 267 | "cell_type": "code", 268 | "execution_count": null, 269 | "metadata": {}, 270 | "outputs": [], 271 | "source": [ 272 | "spark = SparkSession.builder.appName('demo').master(\"local\").getOrCreate()\n", 273 | "\n", 274 | "movieDF = spark.read.format(\"org.apache.spark.sql.cassandra\").options(table=\"movieratings\", keyspace=\"accelerate\").load()\n", 275 | "\n", 276 | "print (\"Table Row Count: \")\n", 277 | "print (movieDF.count())" 278 | ] 279 | }, 280 | { 281 | "cell_type": "code", 282 | "execution_count": null, 283 | "metadata": {}, 284 | "outputs": [], 285 | "source": [ 286 | "showDF(movieDF)" 287 | ] 288 | }, 289 | { 290 | "cell_type": "markdown", 291 | "metadata": {}, 292 | "source": [ 293 | "## This dataset is not in the format we need it to be. We need it to be more in a transaction format. Each user and the list of movies they have reviewed. " 294 | ] 295 | }, 296 | { 297 | "cell_type": "markdown", 298 | "metadata": {}, 299 | "source": [ 300 | "#### Remove the timestamp column since we will not be using that" 301 | ] 302 | }, 303 | { 304 | "cell_type": "code", 305 | "execution_count": null, 306 | "metadata": {}, 307 | "outputs": [], 308 | "source": [ 309 | "newMovieDF = movieDF.drop('timestamp')\n", 310 | "showDF(newMovieDF)" 311 | ] 312 | }, 313 | { 314 | "cell_type": "markdown", 315 | "metadata": {}, 316 | "source": [ 317 | "#### Before we collect the set of movies for each user let's filter out any movies they rated below 3" 318 | ] 319 | }, 320 | { 321 | "cell_type": "code", 322 | "execution_count": null, 323 | "metadata": {}, 324 | "outputs": [], 325 | "source": [ 326 | "newestMovies = newMovieDF.filter(\"rating > 3\")\n", 327 | "showDF(newestMovies)" 328 | ] 329 | }, 330 | { 331 | "cell_type": "markdown", 332 | "metadata": {}, 333 | "source": [ 334 | "#### GroupBy the user id and create a collection set of all the movies they have rated and seen. " 335 | ] 336 | }, 337 | { 338 | "cell_type": "code", 339 | "execution_count": null, 340 | "metadata": {}, 341 | "outputs": [], 342 | "source": [ 343 | "group_user = newestMovies.groupBy('userid').agg(collect_set('movieid').alias('moviesRated'))\n", 344 | "group_user.show()\n" 345 | ] 346 | }, 347 | { 348 | "cell_type": "markdown", 349 | "metadata": {}, 350 | "source": [ 351 | "#### For FP-Growth the list needs to be a column named `items`" 352 | ] 353 | }, 354 | { 355 | "cell_type": "code", 356 | "execution_count": null, 357 | "metadata": {}, 358 | "outputs": [], 359 | "source": [ 360 | "df = group_user.withColumnRenamed(\"moviesRated\", \"items\")\n", 361 | "showDF(df)" 362 | ] 363 | }, 364 | { 365 | "cell_type": "code", 366 | "execution_count": null, 367 | "metadata": {}, 368 | "outputs": [], 369 | "source": [ 370 | "df.select('userid').distinct().count()" 371 | ] 372 | }, 373 | { 374 | "cell_type": "markdown", 375 | "metadata": {}, 376 | "source": [ 377 | "### FPGROWTH for Recommendations\n", 378 | "#### Use Apache Spark MLlib with FPGrowth to find Recommendation \n", 379 | "#### https://spark.apache.org/docs/latest/ml-frequent-pattern-mining.html\n", 380 | "#### https://spark.apache.org/docs/latest/api/python/pyspark.ml.html#pyspark.ml.fpm.FPGrowth" 381 | ] 382 | }, 383 | { 384 | "cell_type": "code", 385 | "execution_count": null, 386 | "metadata": {}, 387 | "outputs": [], 388 | "source": [ 389 | "fpGrowth = FPGrowth(itemsCol=\"items\", minSupport=0.1, minConfidence=0.2)\n", 390 | "model = fpGrowth.fit(df)\n", 391 | "recommendDF=model.transform(df)\n", 392 | "recommendDF.show()" 393 | ] 394 | }, 395 | { 396 | "cell_type": "markdown", 397 | "metadata": {}, 398 | "source": [ 399 | "#### If you have watched these movies `antecedent` then you will like this movie `consquent`" 400 | ] 401 | }, 402 | { 403 | "cell_type": "code", 404 | "execution_count": null, 405 | "metadata": {}, 406 | "outputs": [], 407 | "source": [ 408 | "# Display frequent itemsets.\n", 409 | "#model.freqItemsets.show()\n", 410 | "\n", 411 | "# Display generated association rules.\n", 412 | "dfAssociation = model.associationRules\n", 413 | "\n", 414 | "dfAssociation.show()" 415 | ] 416 | }, 417 | { 418 | "cell_type": "code", 419 | "execution_count": null, 420 | "metadata": {}, 421 | "outputs": [], 422 | "source": [ 423 | "print(\"If you like these movies: \")\n", 424 | "print(list(dfAssociation.select('antecedent').first()))\n", 425 | "print(\"Then you will like this movie:\")\n", 426 | "print(list(dfAssociation.select('consequent').first()))\n", 427 | "\n", 428 | "movieYoulike = list(dfAssociation.select('antecedent').first())\n", 429 | "movieToRecommend=list(dfAssociation.select('consequent').first())" 430 | ] 431 | }, 432 | { 433 | "cell_type": "markdown", 434 | "metadata": {}, 435 | "source": [ 436 | "#### Query database to get movie titles" 437 | ] 438 | }, 439 | { 440 | "cell_type": "code", 441 | "execution_count": null, 442 | "metadata": {}, 443 | "outputs": [], 444 | "source": [ 445 | "query = \"select title from movies WHERE movieid=\"\n", 446 | "query = query + str(movieYoulike[0][0])\n", 447 | "\n", 448 | "rows = session.execute(query)\n", 449 | "print(rows)\n", 450 | "\n", 451 | "for user_row in rows:\n", 452 | " print (user_row.title)\n", 453 | "\n", 454 | "query = \"select title from movies WHERE movieid=\"\n", 455 | "query = query + str(movieYoulike[0][1])\n", 456 | "\n", 457 | "rows = session.execute(query)\n", 458 | "print(rows)\n", 459 | "\n", 460 | "for user_row in rows:\n", 461 | " print (user_row.title)" 462 | ] 463 | }, 464 | { 465 | "cell_type": "markdown", 466 | "metadata": {}, 467 | "source": [ 468 | "#### Then you will like this movie ... " 469 | ] 470 | }, 471 | { 472 | "cell_type": "code", 473 | "execution_count": null, 474 | "metadata": {}, 475 | "outputs": [], 476 | "source": [ 477 | "query = \"select title from movies WHERE movieid=\"\n", 478 | "query = query + str(movieToRecommend[0][0])\n", 479 | "\n", 480 | "rows = session.execute(query)\n", 481 | "print(rows)\n", 482 | "\n", 483 | "for user_row in rows:\n", 484 | " print (user_row.title)" 485 | ] 486 | }, 487 | { 488 | "cell_type": "code", 489 | "execution_count": null, 490 | "metadata": {}, 491 | "outputs": [], 492 | "source": [ 493 | "session.execute(\"\"\"drop table movies\"\"\")\n", 494 | "session.execute(\"\"\"drop table movieratings\"\"\")" 495 | ] 496 | } 497 | ], 498 | "metadata": { 499 | "kernelspec": { 500 | "display_name": "Python 3", 501 | "language": "python", 502 | "name": "python3" 503 | }, 504 | "language_info": { 505 | "codemirror_mode": { 506 | "name": "ipython", 507 | "version": 3 508 | }, 509 | "file_extension": ".py", 510 | "mimetype": "text/x-python", 511 | "name": "python", 512 | "nbconvert_exporter": "python", 513 | "pygments_lexer": "ipython3", 514 | "version": "3.7.3" 515 | } 516 | }, 517 | "nbformat": 4, 518 | "nbformat_minor": 2 519 | } 520 | -------------------------------------------------------------------------------- /dse-studio/notebooks/3a0a2fc4-d7d7-40ba-9438-8d672da3c1d2: -------------------------------------------------------------------------------- 1 | json_notebook_v1{"1":"07494f4b-83e1-4a0b-a12d-b8589166b006","10":"418ed742-cd61-4df8-abd8-07bc56a62e8d","11":"00 - Getting Started with Apache Cassandra™","12":{"1":1570518298,"2":431000000},"13":{"1":1570527776,"2":395000000},"14":false,"15":[{"1":"e3ccc89a-d2e4-4fc6-a032-ffe3e45bab15","10":4,"11":"\n
\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Apache Cassandra™ First Touch
\n\n\nWelcome to the First Touch notebook on Cassandra. In this notebook we will:\n* Investigate the data on a Cassandra cluster\n* Learn some basic CQL\n* Explore some Cassandra schemas\n\nThis notebook is a step-by-step tutorial. \nEach step has a brief discussion section in a cell that describes the step, followed by an exercise in a second cell, where you get to try something out.\nIn some exercises, we'll tell you exactly what to do.\nIn others, we may let you figure it out on your own, because that's a lot more fun than always being told exactly what to do.\n\nBut don't worry. None of these exercises requires you to do anything as difficult as beat Deep Blue at chess. ![Smiley face](https://s3.amazonaws.com/datastaxtraining/solution-days/cassandra-intro/smileyface.png \"Smiley Face\" )\nWe're confident you'll be able to work though each of the exercises in a way that will be educational and fun.\n\nLet's get started!","12":"markdown","13":{"1":"1a18decb-9c33-46e9-a7e4-5bcf1aafe37e","10":{"9":"

\n

\"line\"

\n

Apache Cassandra™ First Touch

\n

Welcome to the First Touch notebook on Cassandra. In this notebook we will:

\n\n

This notebook is a step-by-step tutorial.\n
Each step has a brief discussion section in a cell that describes the step, followed by an exercise in a second cell, where you get to try something out.\n
In some exercises, we'll tell you exactly what to do.\n
In others, we may let you figure it out on your own, because that's a lot more fun than always being told exactly what to do.

\n

But don't worry. None of these exercises requires you to do anything as difficult as beat Deep Blue at chess. \"Smiley\n
We're confident you'll be able to work though each of the exercises in a way that will be educational and fun.

\n

Let's get started!

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"66bedac8-5c03-446b-ae58-44068714c842","10":4,"11":"On next bloc locate the `CL.ONE` on the top right end corner and click on the triangle to execute. This will create object we will need for later\n\nYou shoulg get message `Success - No Data Returned`","12":"markdown","13":{"1":"ef3db0dc-8aad-4abd-9b0f-90dff2c9cfd6","10":{"9":"

On next bloc locate the CL.ONE on the top right end corner and click on the triangle to execute. This will create object we will need for later

\n

You shoulg get message Success - No Data Returned

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"add8e9f0-7dee-467a-b308-810a5c830ac9","10":0,"11":"CREATE KEYSPACE IF NOT EXISTS killrvideo \nWITH REPLICATION = { \n 'class' : 'SimpleStrategy', \n 'replication_factor' : 1 \n};\n\nCREATE TABLE IF NOT EXISTS killrvideo.users (\n userid uuid,\n created_date timestamp,\n email text,\n firstname text,\n lastname text,\n PRIMARY KEY (userid)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.comments_by_user (\n userid uuid,\n commentid timeuuid,\n comment text,\n videoid uuid,\n PRIMARY KEY (userid, commentid)\n) WITH CLUSTERING ORDER BY (commentid DESC);\n\nCREATE TABLE IF NOT EXISTS killrvideo.comments_by_video (\n videoid uuid,\n commentid timeuuid,\n comment text,\n userid uuid,\n PRIMARY KEY (videoid, commentid)\n) WITH CLUSTERING ORDER BY (commentid DESC);\n\nCREATE TABLE IF NOT EXISTS killrvideo.latest_videos (\n yyyymmdd text,\n added_date timestamp,\n videoid uuid,\n name text,\n preview_image_location text,\n userid uuid,\n PRIMARY KEY (yyyymmdd, added_date, videoid)\n) WITH CLUSTERING ORDER BY (added_date DESC, videoid ASC);\n\nCREATE TABLE IF NOT EXISTS killrvideo.location (\n location_id uuid,\n address text,\n city text,\n geo 'org.apache.cassandra.db.marshal.PointType',\n location_name text,\n state text,\n PRIMARY KEY (location_id)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.tags_by_letter (\n first_letter text,\n tag text,\n PRIMARY KEY (first_letter, tag)\n) WITH CLUSTERING ORDER BY (tag ASC);\n\nCREATE TABLE IF NOT EXISTS killrvideo.user_credentials (\n email text,\n \"password\" text,\n userid uuid,\n PRIMARY KEY (email)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.user_videos (\n userid uuid,\n added_date timestamp,\n videoid uuid,\n name text,\n preview_image_location text,\n PRIMARY KEY (userid, added_date, videoid)\n) WITH CLUSTERING ORDER BY (added_date DESC, videoid ASC);\n\n\nCREATE TABLE IF NOT EXISTS killrvideo.video_playback_stats (\n videoid uuid,\n views counter,\n PRIMARY KEY (videoid)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.video_ratings (\n videoid uuid,\n rating_counter counter,\n rating_total counter,\n PRIMARY KEY (videoid)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.video_ratings_by_user (\n videoid uuid,\n userid uuid,\n rating int,\n PRIMARY KEY (videoid, userid)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.video_recommendations (\n userid uuid,\n added_date timestamp,\n videoid uuid,\n authorid uuid,\n name text,\n preview_image_location text,\n rating float,\n PRIMARY KEY (userid, added_date, videoid)\n) WITH CLUSTERING ORDER BY (added_date DESC, videoid ASC);\n\nCREATE TABLE IF NOT EXISTS killrvideo.video_recommendations_by_video (\n videoid uuid,\n userid uuid,\n added_date timestamp static,\n authorid uuid static,\n name text static,\n preview_image_location text static,\n rating float,\n PRIMARY KEY (videoid, userid)\n) WITH CLUSTERING ORDER BY (userid ASC);\n\nCREATE TABLE IF NOT EXISTS killrvideo.videos (\n videoid uuid,\n added_date timestamp,\n description text,\n location text,\n location_type int,\n name text,\n preview_image_location text,\n tags set,\n userid uuid,\n PRIMARY KEY (videoid)\n);\n\nCREATE TABLE IF NOT EXISTS killrvideo.videos_by_tag (\n tag text,\n videoid uuid,\n added_date timestamp,\n name text,\n preview_image_location text,\n tagged_date timestamp,\n userid uuid,\n PRIMARY KEY (tag, videoid)\n) WITH CLUSTERING ORDER BY (videoid ASC);\n\n\n// Insert Users\nINSERT INTO killrvideo.users(userid,created_date, email, firstname, lastname) VALUES(\n9a76b713-fe9d-4696-a40d-d9011437a78d, toTimestamp(now()), 'hroseamanon@cnbc.com', 'Hartwell', 'Roseaman');\n\nINSERT INTO killrvideo.users(userid,created_date, email, firstname, lastname) VALUES(\nb4e5d031-d0cb-41b9-bb87-d073d6dd5a3a, toTimestamp(now()), 'cjoddinsph@friendfeed.com','Corly','Joddins');\n\nINSERT INTO killrvideo.users(userid,created_date, email, firstname, lastname) VALUES(\n35323518-d145-4657-9a3b-72c624defc4d, toTimestamp(now()), 'Harold_Hermann26@example.com', 'Harold', 'Hermann');\n\nINSERT INTO killrvideo.users(userid,created_date, email, firstname, lastname) VALUES(\nfecc4324-7083-4ebf-b057-9582c7bd20bf, toTimestamp(now()), 'wcourvertp8@soundcloud.com', 'Windham', 'Courvert');\n\nINSERT INTO killrvideo.users(userid,created_date, email, firstname, lastname) VALUES(\n2f033483-151f-4628-b45f-07c3f6168af5, toTimestamp(now()), 'ajohannespw@cmu.edu', 'Asia', 'Johannes');\n\n// Insert Comments\n\nINSERT INTO killrvideo.comments_by_user (userid, commentid, comment, videoid) VALUES(\nb4e5d031-d0cb-41b9-bb87-d073d6dd5a3a,be302000-77f4-11e7-bd88-ebc1ee0c4297, 'comment1', 4900e9c2-f105-41c2-b7dd-fc79840bf42e);\n\nINSERT INTO killrvideo.comments_by_user (userid, commentid, comment, videoid) VALUES(\nb4e5d031-d0cb-41b9-bb87-d073d6dd5a3a, 2c0ff110-77f3-11e7-bd88-ebc1ee0c4297, 'Comment 2' , 933efc48-4799-4661-b1c6-1d0682e656ae);\n\nINSERT INTO killrvideo.comments_by_user (userid, commentid, comment, videoid) VALUES(\nb4e5d031-d0cb-41b9-bb87-d073d6dd5a3b,6ab37d50-77ea-11e7-9867-cd21221d07b3,'test',e05a0435-d522-43dc-b45e-df03e03ca133);\n\nINSERT INTO killrvideo.comments_by_user (userid, commentid, comment, videoid) VALUES(\nb4e5d031-d0cb-41b9-bb87-d073d6dd5a3e,62e333d0-77e6-11e7-be0c-1170ace5d8ba,'test2',0a70da99-6b95-4f6d-8e25-3d156d7ac505);\n\n\n\n","12":"cql","16":true,"17":true,"18":{},"23":2611,"25":"CL.ONE"},{"1":"2b191f97-41b5-4b86-8bb1-0b4b3f2a401b","10":4,"11":"![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n###
Step 1: The Schema Viewer
\nIf you are seeing this notebook, that means that you have access to a cluster.\nWe have set up the cluster and have already installed some data on it for you.\n\nLet's start by investigating the keyspaces that your cluster already has.\nRemember, a \"keyspace\" is what the relational world calls a \"database\".\n\nTo use Studio's tool to see the schemas, click on the button in the top-right corner of your browser window:\n
![schema button](https://s3.amazonaws.com/datastaxtraining/developer-day/cassandra-intro/data-modeling/schema.png \"schema button\" )
\n\nYou see that you are connected to the `Cassandra Day Cluster`, but no schema is selected.\nClick the `Schema` dropdown, select `CQL` and select the `killrvideo` schema.\n
![schema dropdown](https://s3.amazonaws.com/datastaxtraining/solution-days/cassandra-intro/FirstTouch/SchemaDropdown.png \"schema dropdown\" )
\n\nThis should allow you to see the `killrvideo` schema as shown here:\n
![table names](https://s3.amazonaws.com/datastaxtraining/solution-days/cassandra-intro/FirstTouch/TableNames.png \"table names\" )
\n\nYou can check out the `users` table by expandning it.\nYou can also see the columns in the table and its primary key by expanding those sections:\n
![expanding users](https://s3.amazonaws.com/datastaxtraining/solution-days/cassandra-intro/FirstTouch/UserTable.png \"expanding users\" )
","12":"markdown","13":{"1":"60ec8be5-060b-4203-b14c-54c3a7e6fd64","10":{"9":"

\"line\"

\n

Step 1: The Schema Viewer

\n

If you are seeing this notebook, that means that you have access to a cluster.\n
We have set up the cluster and have already installed some data on it for you.

\n

Let's start by investigating the keyspaces that your cluster already has.\n
Remember, a “keyspace” is what the relational world calls a “database”.

\n

To use Studio's tool to see the schemas, click on the button in the top-right corner of your browser window:\n

\"schema

\n

You see that you are connected to the Cassandra Day Cluster, but no schema is selected.\n
Click the Schema dropdown, select CQL and select the killrvideo schema.\n

\"schema

\n

This should allow you to see the killrvideo schema as shown here:\n

\"table

\n

You can check out the users table by expandning it.\n
You can also see the columns in the table and its primary key by expanding those sections:\n

\"expanding

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"7bd27858-642c-4a62-b8eb-e9b32657e8b5","10":4,"11":"![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n###
Step 2: Viewing Data
\nIn this step, let's see how we can look at the data in the `users` table.\nWe'll use a simple CQL command that retrieves all the data in the table.\nDon't worry, Studio will paginate the results for us.\n\nIn the following cell, try this command: `SELECT * FROM killrvideo.users;`\n\nPro Tip: You would never want to execute this command in a true production environment because it would have significant performance implications. We use the command here for illustrative purposes only - to give you a gentle introduction to CQL.\n","12":"markdown","13":{"1":"dd804b02-dd9d-42a5-828d-5a8ae3ca5398","10":{"9":"

\"line\"

\n

Step 2: Viewing Data

\n

In this step, let's see how we can look at the data in the users table.\n
We'll use a simple CQL command that retrieves all the data in the table.\n
Don't worry, Studio will paginate the results for us.

\n

In the following cell, try this command: SELECT * FROM killrvideo.users;

\n

Pro Tip: You would never want to execute this command in a true production environment because it would have significant performance implications. We use the command here for illustrative purposes only - to give you a gentle introduction to CQL.

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"b88cf06c-c0ae-4f73-9652-387d9f237e72","10":0,"11":"// Enter the SELECT command here followed by shift+enter or pressing the CL.ONE button:\n","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"127dbc38-9550-4a0b-9bdb-94ab5a31963a","10":4,"11":"![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n###
Step 3: Limiting the Columns
\nIn the results from the previous step, you see that the columns correspond with the columns we saw when we investigated the `killrvideo` schema.\nThe first column, the `index`, of course isn't part of the schema, it's just the number of the column in the results.\nYou may have also noticed that CQL looks a lot like SQL.\nThis syntactical similarity makes it a little more intuitive to use CQL, assuming you are already familiar with SQL.\nFor example, if we don't want to get all the columns back, we can project only those columns we want, in the order we want - just like SQL.\n\nCan you guess how you might select only the `firstname`, `lastname` and `userid` columns?\nTry it in the next cell:","12":"markdown","13":{"1":"3b7c81c1-ea2d-4b78-bee6-54e7fc76dda7","10":{"9":"

\"line\"

\n

Step 3: Limiting the Columns

\n

In the results from the previous step, you see that the columns correspond with the columns we saw when we investigated the killrvideo schema.\n
The first column, the index, of course isn't part of the schema, it's just the number of the column in the results.\n
You may have also noticed that CQL looks a lot like SQL.\n
This syntactical similarity makes it a little more intuitive to use CQL, assuming you are already familiar with SQL.\n
For example, if we don't want to get all the columns back, we can project only those columns we want, in the order we want - just like SQL.

\n

Can you guess how you might select only the firstname, lastname and userid columns?\n
Try it in the next cell:

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"ca1a20a1-0561-46ec-a1d3-b6b49c3a9b88","10":0,"11":"// Try to select only the firstname, lastname and userid columns here:\n// (hint: you can replace the * in the previous query with a list of columns)\n","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"4125869c-a52c-4a2b-b79b-ef1dffb56bf0","10":4,"11":"![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n###
Step 4: Getting a Single Partition
\nYou may have noticed in the schema, that the `userid` column is the partition key.\nA partition key is the key we use to retrieve a partition, which consists of one or more rows.\nIn the `users` table, the partition key corresponds to a single row, but in the `comments_by_user` table, a partition may consist of several rows - all the comments made by the specified user.\n\nLet's try a query and see how that works.\nLet's retrieve all the comments made by Corly Joddins (the first result in the previous query).\n\nSPOILER ALERT: the rest of this cell explains how to do this, so if you think you want to try it on your own, skip to the next cell without expanding.\n\n
\nClick here for the explanation.\nOnce again, CQL looks a lot like SQL - specifically, you can use a `WHERE` clause to identify the specific partition key.\nThe `WHERE` clause would be `WHERE userid = ` and goes right after the name of the table and before the final `;`.\nYou don't add any quotes or anything around the userid value, just copy it from the previous query results and past it in the query.\n
\n\n\n","12":"markdown","13":{"1":"fc47c932-766c-4d50-8a19-886f2a58d6c1","10":{"9":"

\"line\"

\n

Step 4: Getting a Single Partition

\n

You may have noticed in the schema, that the userid column is the partition key.\n
A partition key is the key we use to retrieve a partition, which consists of one or more rows.\n
In the users table, the partition key corresponds to a single row, but in the comments_by_user table, a partition may consist of several rows - all the comments made by the specified user.

\n

Let's try a query and see how that works.\n
Let's retrieve all the comments made by Corly Joddins (the first result in the previous query).

\n

SPOILER ALERT: the rest of this cell explains how to do this, so if you think you want to try it on your own, skip to the next cell without expanding.

\n

\n
Click here for the explanation.\n
Once again, CQL looks a lot like SQL - specifically, you can use a WHERE clause to identify the specific partition key.\n
The WHERE clause would be WHERE userid = <put the userid here> and goes right after the name of the table and before the final ;.\n
You don't add any quotes or anything around the userid value, just copy it from the previous query results and past it in the query.\n

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"1903c7f5-4426-4689-94fe-22426ee49d39","10":0,"11":"","12":"cql","16":true,"17":false,"25":"CL.ONE"},{"1":"a7f9042f-5794-40bb-b9ed-843804527130","10":4,"11":"It appears that Corly creates all the comments in Latin, but you get the idea.\nRemember, a partition contains one or more rows, which allows you to create queries that can find all your results with a single access - and do it very quickly!","12":"markdown","13":{"1":"b48b2604-b89d-4c53-9b74-45651ab42380","10":{"9":"

It appears that Corly creates all the comments in Latin, but you get the idea.\n
Remember, a partition contains one or more rows, which allows you to create queries that can find all your results with a single access - and do it very quickly!

\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"},{"1":"83472f8e-4068-4583-86fa-350973ddb6d5","10":4,"11":"![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Congratulations!!!!!
\n#### You have completed the _Cassandra First Touch_ notebook!\n\nNow you have an intuitive feel for what Apache Cassandra™ can do.\n\nLet's review what you have learned:\n* What Cassandra schemas look like\n* How to investigate a cluster's schemas using both CQL and DSE Studio\n* How to retrieve data from a Cassandra table\n* How to project specific columns from a table\n* How to limit a Cassandra query to a single parition\n\nWOW! That's a great start!\n\n![line](https://datastaxtraining.s3.amazonaws.com/developer-day/lineblue.png \"line\" )\n#
Want to Know More?
\n#### Check out these great FREE classes on DataStax Academy:\n* [DS201: DataStax Enterprise Foundations of Apache Cassandra™](http://academy.datastax.com/resources/ds201-foundations-apache-cassandra \"DS201: DataStax Enterprise Foundations of Apache Cassandra™\")\n* [DS210: DataStax Enterprise Operations with Apache Cassandra™](https://academy.datastax.com/resources/ds210-datastax-enterprise-operations-apache-cassandra \"DS210: DataStax Enterprise Operations with Apache Cassandra™\")\n* [DS220: Data Modeling](https://academy.datastax.com/resources/ds220-data-modeling \"DS220: Data Modeling\")\n","12":"markdown","13":{"1":"a6725524-3e27-4f4d-8c4f-396cfe5929c0","10":{"9":"

\"line\"

\n

Congratulations!!!!!

\n

You have completed the Cassandra First Touch notebook!

\n

Now you have an intuitive feel for what Apache Cassandra™ can do.

\n

Let's review what you have learned:

\n\n

WOW! That's a great start!

\n

\"line\"

\n

Want to Know More?

\n

Check out these great FREE classes on DataStax Academy:

\n\n"},"11":4,"12":false},"16":true,"17":true,"18":{},"25":"CL.ONE"}],"16":{"1":{}},"17":""} -------------------------------------------------------------------------------- /jupyter/data/car_evaluation.csv: -------------------------------------------------------------------------------- 1 | vhigh,vhigh,2,2,small,low,unacc 2 | vhigh,vhigh,2,2,small,med,unacc 3 | vhigh,vhigh,2,2,small,high,unacc 4 | vhigh,vhigh,2,2,med,low,unacc 5 | vhigh,vhigh,2,2,med,med,unacc 6 | vhigh,vhigh,2,2,med,high,unacc 7 | vhigh,vhigh,2,2,big,low,unacc 8 | vhigh,vhigh,2,2,big,med,unacc 9 | vhigh,vhigh,2,2,big,high,unacc 10 | vhigh,vhigh,2,4,small,low,unacc 11 | vhigh,vhigh,2,4,small,med,unacc 12 | vhigh,vhigh,2,4,small,high,unacc 13 | vhigh,vhigh,2,4,med,low,unacc 14 | vhigh,vhigh,2,4,med,med,unacc 15 | vhigh,vhigh,2,4,med,high,unacc 16 | vhigh,vhigh,2,4,big,low,unacc 17 | vhigh,vhigh,2,4,big,med,unacc 18 | vhigh,vhigh,2,4,big,high,unacc 19 | vhigh,vhigh,2,more,small,low,unacc 20 | vhigh,vhigh,2,more,small,med,unacc 21 | vhigh,vhigh,2,more,small,high,unacc 22 | vhigh,vhigh,2,more,med,low,unacc 23 | vhigh,vhigh,2,more,med,med,unacc 24 | vhigh,vhigh,2,more,med,high,unacc 25 | vhigh,vhigh,2,more,big,low,unacc 26 | vhigh,vhigh,2,more,big,med,unacc 27 | vhigh,vhigh,2,more,big,high,unacc 28 | vhigh,vhigh,3,2,small,low,unacc 29 | vhigh,vhigh,3,2,small,med,unacc 30 | vhigh,vhigh,3,2,small,high,unacc 31 | vhigh,vhigh,3,2,med,low,unacc 32 | vhigh,vhigh,3,2,med,med,unacc 33 | vhigh,vhigh,3,2,med,high,unacc 34 | vhigh,vhigh,3,2,big,low,unacc 35 | vhigh,vhigh,3,2,big,med,unacc 36 | vhigh,vhigh,3,2,big,high,unacc 37 | vhigh,vhigh,3,4,small,low,unacc 38 | vhigh,vhigh,3,4,small,med,unacc 39 | vhigh,vhigh,3,4,small,high,unacc 40 | vhigh,vhigh,3,4,med,low,unacc 41 | vhigh,vhigh,3,4,med,med,unacc 42 | vhigh,vhigh,3,4,med,high,unacc 43 | vhigh,vhigh,3,4,big,low,unacc 44 | vhigh,vhigh,3,4,big,med,unacc 45 | vhigh,vhigh,3,4,big,high,unacc 46 | vhigh,vhigh,3,more,small,low,unacc 47 | vhigh,vhigh,3,more,small,med,unacc 48 | vhigh,vhigh,3,more,small,high,unacc 49 | vhigh,vhigh,3,more,med,low,unacc 50 | vhigh,vhigh,3,more,med,med,unacc 51 | vhigh,vhigh,3,more,med,high,unacc 52 | vhigh,vhigh,3,more,big,low,unacc 53 | vhigh,vhigh,3,more,big,med,unacc 54 | vhigh,vhigh,3,more,big,high,unacc 55 | vhigh,vhigh,4,2,small,low,unacc 56 | vhigh,vhigh,4,2,small,med,unacc 57 | vhigh,vhigh,4,2,small,high,unacc 58 | vhigh,vhigh,4,2,med,low,unacc 59 | vhigh,vhigh,4,2,med,med,unacc 60 | vhigh,vhigh,4,2,med,high,unacc 61 | vhigh,vhigh,4,2,big,low,unacc 62 | vhigh,vhigh,4,2,big,med,unacc 63 | vhigh,vhigh,4,2,big,high,unacc 64 | vhigh,vhigh,4,4,small,low,unacc 65 | vhigh,vhigh,4,4,small,med,unacc 66 | vhigh,vhigh,4,4,small,high,unacc 67 | vhigh,vhigh,4,4,med,low,unacc 68 | vhigh,vhigh,4,4,med,med,unacc 69 | vhigh,vhigh,4,4,med,high,unacc 70 | vhigh,vhigh,4,4,big,low,unacc 71 | vhigh,vhigh,4,4,big,med,unacc 72 | vhigh,vhigh,4,4,big,high,unacc 73 | vhigh,vhigh,4,more,small,low,unacc 74 | vhigh,vhigh,4,more,small,med,unacc 75 | vhigh,vhigh,4,more,small,high,unacc 76 | vhigh,vhigh,4,more,med,low,unacc 77 | vhigh,vhigh,4,more,med,med,unacc 78 | vhigh,vhigh,4,more,med,high,unacc 79 | vhigh,vhigh,4,more,big,low,unacc 80 | vhigh,vhigh,4,more,big,med,unacc 81 | vhigh,vhigh,4,more,big,high,unacc 82 | vhigh,vhigh,5more,2,small,low,unacc 83 | vhigh,vhigh,5more,2,small,med,unacc 84 | vhigh,vhigh,5more,2,small,high,unacc 85 | vhigh,vhigh,5more,2,med,low,unacc 86 | vhigh,vhigh,5more,2,med,med,unacc 87 | vhigh,vhigh,5more,2,med,high,unacc 88 | vhigh,vhigh,5more,2,big,low,unacc 89 | vhigh,vhigh,5more,2,big,med,unacc 90 | vhigh,vhigh,5more,2,big,high,unacc 91 | vhigh,vhigh,5more,4,small,low,unacc 92 | vhigh,vhigh,5more,4,small,med,unacc 93 | vhigh,vhigh,5more,4,small,high,unacc 94 | vhigh,vhigh,5more,4,med,low,unacc 95 | vhigh,vhigh,5more,4,med,med,unacc 96 | vhigh,vhigh,5more,4,med,high,unacc 97 | vhigh,vhigh,5more,4,big,low,unacc 98 | vhigh,vhigh,5more,4,big,med,unacc 99 | vhigh,vhigh,5more,4,big,high,unacc 100 | vhigh,vhigh,5more,more,small,low,unacc 101 | vhigh,vhigh,5more,more,small,med,unacc 102 | vhigh,vhigh,5more,more,small,high,unacc 103 | vhigh,vhigh,5more,more,med,low,unacc 104 | vhigh,vhigh,5more,more,med,med,unacc 105 | vhigh,vhigh,5more,more,med,high,unacc 106 | vhigh,vhigh,5more,more,big,low,unacc 107 | vhigh,vhigh,5more,more,big,med,unacc 108 | vhigh,vhigh,5more,more,big,high,unacc 109 | vhigh,high,2,2,small,low,unacc 110 | vhigh,high,2,2,small,med,unacc 111 | vhigh,high,2,2,small,high,unacc 112 | vhigh,high,2,2,med,low,unacc 113 | vhigh,high,2,2,med,med,unacc 114 | vhigh,high,2,2,med,high,unacc 115 | vhigh,high,2,2,big,low,unacc 116 | vhigh,high,2,2,big,med,unacc 117 | vhigh,high,2,2,big,high,unacc 118 | vhigh,high,2,4,small,low,unacc 119 | vhigh,high,2,4,small,med,unacc 120 | vhigh,high,2,4,small,high,unacc 121 | vhigh,high,2,4,med,low,unacc 122 | vhigh,high,2,4,med,med,unacc 123 | vhigh,high,2,4,med,high,unacc 124 | vhigh,high,2,4,big,low,unacc 125 | vhigh,high,2,4,big,med,unacc 126 | vhigh,high,2,4,big,high,unacc 127 | vhigh,high,2,more,small,low,unacc 128 | vhigh,high,2,more,small,med,unacc 129 | vhigh,high,2,more,small,high,unacc 130 | vhigh,high,2,more,med,low,unacc 131 | vhigh,high,2,more,med,med,unacc 132 | vhigh,high,2,more,med,high,unacc 133 | vhigh,high,2,more,big,low,unacc 134 | vhigh,high,2,more,big,med,unacc 135 | vhigh,high,2,more,big,high,unacc 136 | vhigh,high,3,2,small,low,unacc 137 | vhigh,high,3,2,small,med,unacc 138 | vhigh,high,3,2,small,high,unacc 139 | vhigh,high,3,2,med,low,unacc 140 | vhigh,high,3,2,med,med,unacc 141 | vhigh,high,3,2,med,high,unacc 142 | vhigh,high,3,2,big,low,unacc 143 | vhigh,high,3,2,big,med,unacc 144 | vhigh,high,3,2,big,high,unacc 145 | vhigh,high,3,4,small,low,unacc 146 | vhigh,high,3,4,small,med,unacc 147 | vhigh,high,3,4,small,high,unacc 148 | vhigh,high,3,4,med,low,unacc 149 | vhigh,high,3,4,med,med,unacc 150 | vhigh,high,3,4,med,high,unacc 151 | vhigh,high,3,4,big,low,unacc 152 | vhigh,high,3,4,big,med,unacc 153 | vhigh,high,3,4,big,high,unacc 154 | vhigh,high,3,more,small,low,unacc 155 | vhigh,high,3,more,small,med,unacc 156 | vhigh,high,3,more,small,high,unacc 157 | vhigh,high,3,more,med,low,unacc 158 | vhigh,high,3,more,med,med,unacc 159 | vhigh,high,3,more,med,high,unacc 160 | vhigh,high,3,more,big,low,unacc 161 | vhigh,high,3,more,big,med,unacc 162 | vhigh,high,3,more,big,high,unacc 163 | vhigh,high,4,2,small,low,unacc 164 | vhigh,high,4,2,small,med,unacc 165 | vhigh,high,4,2,small,high,unacc 166 | vhigh,high,4,2,med,low,unacc 167 | vhigh,high,4,2,med,med,unacc 168 | vhigh,high,4,2,med,high,unacc 169 | vhigh,high,4,2,big,low,unacc 170 | vhigh,high,4,2,big,med,unacc 171 | vhigh,high,4,2,big,high,unacc 172 | vhigh,high,4,4,small,low,unacc 173 | vhigh,high,4,4,small,med,unacc 174 | vhigh,high,4,4,small,high,unacc 175 | vhigh,high,4,4,med,low,unacc 176 | vhigh,high,4,4,med,med,unacc 177 | vhigh,high,4,4,med,high,unacc 178 | vhigh,high,4,4,big,low,unacc 179 | vhigh,high,4,4,big,med,unacc 180 | vhigh,high,4,4,big,high,unacc 181 | vhigh,high,4,more,small,low,unacc 182 | vhigh,high,4,more,small,med,unacc 183 | vhigh,high,4,more,small,high,unacc 184 | vhigh,high,4,more,med,low,unacc 185 | vhigh,high,4,more,med,med,unacc 186 | vhigh,high,4,more,med,high,unacc 187 | vhigh,high,4,more,big,low,unacc 188 | vhigh,high,4,more,big,med,unacc 189 | vhigh,high,4,more,big,high,unacc 190 | vhigh,high,5more,2,small,low,unacc 191 | vhigh,high,5more,2,small,med,unacc 192 | vhigh,high,5more,2,small,high,unacc 193 | vhigh,high,5more,2,med,low,unacc 194 | vhigh,high,5more,2,med,med,unacc 195 | vhigh,high,5more,2,med,high,unacc 196 | vhigh,high,5more,2,big,low,unacc 197 | vhigh,high,5more,2,big,med,unacc 198 | vhigh,high,5more,2,big,high,unacc 199 | vhigh,high,5more,4,small,low,unacc 200 | vhigh,high,5more,4,small,med,unacc 201 | vhigh,high,5more,4,small,high,unacc 202 | vhigh,high,5more,4,med,low,unacc 203 | vhigh,high,5more,4,med,med,unacc 204 | vhigh,high,5more,4,med,high,unacc 205 | vhigh,high,5more,4,big,low,unacc 206 | vhigh,high,5more,4,big,med,unacc 207 | vhigh,high,5more,4,big,high,unacc 208 | vhigh,high,5more,more,small,low,unacc 209 | vhigh,high,5more,more,small,med,unacc 210 | vhigh,high,5more,more,small,high,unacc 211 | vhigh,high,5more,more,med,low,unacc 212 | vhigh,high,5more,more,med,med,unacc 213 | vhigh,high,5more,more,med,high,unacc 214 | vhigh,high,5more,more,big,low,unacc 215 | vhigh,high,5more,more,big,med,unacc 216 | vhigh,high,5more,more,big,high,unacc 217 | vhigh,med,2,2,small,low,unacc 218 | vhigh,med,2,2,small,med,unacc 219 | vhigh,med,2,2,small,high,unacc 220 | vhigh,med,2,2,med,low,unacc 221 | vhigh,med,2,2,med,med,unacc 222 | vhigh,med,2,2,med,high,unacc 223 | vhigh,med,2,2,big,low,unacc 224 | vhigh,med,2,2,big,med,unacc 225 | vhigh,med,2,2,big,high,unacc 226 | vhigh,med,2,4,small,low,unacc 227 | vhigh,med,2,4,small,med,unacc 228 | vhigh,med,2,4,small,high,acc 229 | vhigh,med,2,4,med,low,unacc 230 | vhigh,med,2,4,med,med,unacc 231 | vhigh,med,2,4,med,high,acc 232 | vhigh,med,2,4,big,low,unacc 233 | vhigh,med,2,4,big,med,acc 234 | vhigh,med,2,4,big,high,acc 235 | vhigh,med,2,more,small,low,unacc 236 | vhigh,med,2,more,small,med,unacc 237 | vhigh,med,2,more,small,high,unacc 238 | vhigh,med,2,more,med,low,unacc 239 | vhigh,med,2,more,med,med,unacc 240 | vhigh,med,2,more,med,high,acc 241 | vhigh,med,2,more,big,low,unacc 242 | vhigh,med,2,more,big,med,acc 243 | vhigh,med,2,more,big,high,acc 244 | vhigh,med,3,2,small,low,unacc 245 | vhigh,med,3,2,small,med,unacc 246 | vhigh,med,3,2,small,high,unacc 247 | vhigh,med,3,2,med,low,unacc 248 | vhigh,med,3,2,med,med,unacc 249 | vhigh,med,3,2,med,high,unacc 250 | vhigh,med,3,2,big,low,unacc 251 | vhigh,med,3,2,big,med,unacc 252 | vhigh,med,3,2,big,high,unacc 253 | vhigh,med,3,4,small,low,unacc 254 | vhigh,med,3,4,small,med,unacc 255 | vhigh,med,3,4,small,high,acc 256 | vhigh,med,3,4,med,low,unacc 257 | vhigh,med,3,4,med,med,unacc 258 | vhigh,med,3,4,med,high,acc 259 | vhigh,med,3,4,big,low,unacc 260 | vhigh,med,3,4,big,med,acc 261 | vhigh,med,3,4,big,high,acc 262 | vhigh,med,3,more,small,low,unacc 263 | vhigh,med,3,more,small,med,unacc 264 | vhigh,med,3,more,small,high,acc 265 | vhigh,med,3,more,med,low,unacc 266 | vhigh,med,3,more,med,med,acc 267 | vhigh,med,3,more,med,high,acc 268 | vhigh,med,3,more,big,low,unacc 269 | vhigh,med,3,more,big,med,acc 270 | vhigh,med,3,more,big,high,acc 271 | vhigh,med,4,2,small,low,unacc 272 | vhigh,med,4,2,small,med,unacc 273 | vhigh,med,4,2,small,high,unacc 274 | vhigh,med,4,2,med,low,unacc 275 | vhigh,med,4,2,med,med,unacc 276 | vhigh,med,4,2,med,high,unacc 277 | vhigh,med,4,2,big,low,unacc 278 | vhigh,med,4,2,big,med,unacc 279 | vhigh,med,4,2,big,high,unacc 280 | vhigh,med,4,4,small,low,unacc 281 | vhigh,med,4,4,small,med,unacc 282 | vhigh,med,4,4,small,high,acc 283 | vhigh,med,4,4,med,low,unacc 284 | vhigh,med,4,4,med,med,acc 285 | vhigh,med,4,4,med,high,acc 286 | vhigh,med,4,4,big,low,unacc 287 | vhigh,med,4,4,big,med,acc 288 | vhigh,med,4,4,big,high,acc 289 | vhigh,med,4,more,small,low,unacc 290 | vhigh,med,4,more,small,med,unacc 291 | vhigh,med,4,more,small,high,acc 292 | vhigh,med,4,more,med,low,unacc 293 | vhigh,med,4,more,med,med,acc 294 | vhigh,med,4,more,med,high,acc 295 | vhigh,med,4,more,big,low,unacc 296 | vhigh,med,4,more,big,med,acc 297 | vhigh,med,4,more,big,high,acc 298 | vhigh,med,5more,2,small,low,unacc 299 | vhigh,med,5more,2,small,med,unacc 300 | vhigh,med,5more,2,small,high,unacc 301 | vhigh,med,5more,2,med,low,unacc 302 | vhigh,med,5more,2,med,med,unacc 303 | vhigh,med,5more,2,med,high,unacc 304 | vhigh,med,5more,2,big,low,unacc 305 | vhigh,med,5more,2,big,med,unacc 306 | vhigh,med,5more,2,big,high,unacc 307 | vhigh,med,5more,4,small,low,unacc 308 | vhigh,med,5more,4,small,med,unacc 309 | vhigh,med,5more,4,small,high,acc 310 | vhigh,med,5more,4,med,low,unacc 311 | vhigh,med,5more,4,med,med,acc 312 | vhigh,med,5more,4,med,high,acc 313 | vhigh,med,5more,4,big,low,unacc 314 | vhigh,med,5more,4,big,med,acc 315 | vhigh,med,5more,4,big,high,acc 316 | vhigh,med,5more,more,small,low,unacc 317 | vhigh,med,5more,more,small,med,unacc 318 | vhigh,med,5more,more,small,high,acc 319 | vhigh,med,5more,more,med,low,unacc 320 | vhigh,med,5more,more,med,med,acc 321 | vhigh,med,5more,more,med,high,acc 322 | vhigh,med,5more,more,big,low,unacc 323 | vhigh,med,5more,more,big,med,acc 324 | vhigh,med,5more,more,big,high,acc 325 | vhigh,low,2,2,small,low,unacc 326 | vhigh,low,2,2,small,med,unacc 327 | vhigh,low,2,2,small,high,unacc 328 | vhigh,low,2,2,med,low,unacc 329 | vhigh,low,2,2,med,med,unacc 330 | vhigh,low,2,2,med,high,unacc 331 | vhigh,low,2,2,big,low,unacc 332 | vhigh,low,2,2,big,med,unacc 333 | vhigh,low,2,2,big,high,unacc 334 | vhigh,low,2,4,small,low,unacc 335 | vhigh,low,2,4,small,med,unacc 336 | vhigh,low,2,4,small,high,acc 337 | vhigh,low,2,4,med,low,unacc 338 | vhigh,low,2,4,med,med,unacc 339 | vhigh,low,2,4,med,high,acc 340 | vhigh,low,2,4,big,low,unacc 341 | vhigh,low,2,4,big,med,acc 342 | vhigh,low,2,4,big,high,acc 343 | vhigh,low,2,more,small,low,unacc 344 | vhigh,low,2,more,small,med,unacc 345 | vhigh,low,2,more,small,high,unacc 346 | vhigh,low,2,more,med,low,unacc 347 | vhigh,low,2,more,med,med,unacc 348 | vhigh,low,2,more,med,high,acc 349 | vhigh,low,2,more,big,low,unacc 350 | vhigh,low,2,more,big,med,acc 351 | vhigh,low,2,more,big,high,acc 352 | vhigh,low,3,2,small,low,unacc 353 | vhigh,low,3,2,small,med,unacc 354 | vhigh,low,3,2,small,high,unacc 355 | vhigh,low,3,2,med,low,unacc 356 | vhigh,low,3,2,med,med,unacc 357 | vhigh,low,3,2,med,high,unacc 358 | vhigh,low,3,2,big,low,unacc 359 | vhigh,low,3,2,big,med,unacc 360 | vhigh,low,3,2,big,high,unacc 361 | vhigh,low,3,4,small,low,unacc 362 | vhigh,low,3,4,small,med,unacc 363 | vhigh,low,3,4,small,high,acc 364 | vhigh,low,3,4,med,low,unacc 365 | vhigh,low,3,4,med,med,unacc 366 | vhigh,low,3,4,med,high,acc 367 | vhigh,low,3,4,big,low,unacc 368 | vhigh,low,3,4,big,med,acc 369 | vhigh,low,3,4,big,high,acc 370 | vhigh,low,3,more,small,low,unacc 371 | vhigh,low,3,more,small,med,unacc 372 | vhigh,low,3,more,small,high,acc 373 | vhigh,low,3,more,med,low,unacc 374 | vhigh,low,3,more,med,med,acc 375 | vhigh,low,3,more,med,high,acc 376 | vhigh,low,3,more,big,low,unacc 377 | vhigh,low,3,more,big,med,acc 378 | vhigh,low,3,more,big,high,acc 379 | vhigh,low,4,2,small,low,unacc 380 | vhigh,low,4,2,small,med,unacc 381 | vhigh,low,4,2,small,high,unacc 382 | vhigh,low,4,2,med,low,unacc 383 | vhigh,low,4,2,med,med,unacc 384 | vhigh,low,4,2,med,high,unacc 385 | vhigh,low,4,2,big,low,unacc 386 | vhigh,low,4,2,big,med,unacc 387 | vhigh,low,4,2,big,high,unacc 388 | vhigh,low,4,4,small,low,unacc 389 | vhigh,low,4,4,small,med,unacc 390 | vhigh,low,4,4,small,high,acc 391 | vhigh,low,4,4,med,low,unacc 392 | vhigh,low,4,4,med,med,acc 393 | vhigh,low,4,4,med,high,acc 394 | vhigh,low,4,4,big,low,unacc 395 | vhigh,low,4,4,big,med,acc 396 | vhigh,low,4,4,big,high,acc 397 | vhigh,low,4,more,small,low,unacc 398 | vhigh,low,4,more,small,med,unacc 399 | vhigh,low,4,more,small,high,acc 400 | vhigh,low,4,more,med,low,unacc 401 | vhigh,low,4,more,med,med,acc 402 | vhigh,low,4,more,med,high,acc 403 | vhigh,low,4,more,big,low,unacc 404 | vhigh,low,4,more,big,med,acc 405 | vhigh,low,4,more,big,high,acc 406 | vhigh,low,5more,2,small,low,unacc 407 | vhigh,low,5more,2,small,med,unacc 408 | vhigh,low,5more,2,small,high,unacc 409 | vhigh,low,5more,2,med,low,unacc 410 | vhigh,low,5more,2,med,med,unacc 411 | vhigh,low,5more,2,med,high,unacc 412 | vhigh,low,5more,2,big,low,unacc 413 | vhigh,low,5more,2,big,med,unacc 414 | vhigh,low,5more,2,big,high,unacc 415 | vhigh,low,5more,4,small,low,unacc 416 | vhigh,low,5more,4,small,med,unacc 417 | vhigh,low,5more,4,small,high,acc 418 | vhigh,low,5more,4,med,low,unacc 419 | vhigh,low,5more,4,med,med,acc 420 | vhigh,low,5more,4,med,high,acc 421 | vhigh,low,5more,4,big,low,unacc 422 | vhigh,low,5more,4,big,med,acc 423 | vhigh,low,5more,4,big,high,acc 424 | vhigh,low,5more,more,small,low,unacc 425 | vhigh,low,5more,more,small,med,unacc 426 | vhigh,low,5more,more,small,high,acc 427 | vhigh,low,5more,more,med,low,unacc 428 | vhigh,low,5more,more,med,med,acc 429 | vhigh,low,5more,more,med,high,acc 430 | vhigh,low,5more,more,big,low,unacc 431 | vhigh,low,5more,more,big,med,acc 432 | vhigh,low,5more,more,big,high,acc 433 | high,vhigh,2,2,small,low,unacc 434 | high,vhigh,2,2,small,med,unacc 435 | high,vhigh,2,2,small,high,unacc 436 | high,vhigh,2,2,med,low,unacc 437 | high,vhigh,2,2,med,med,unacc 438 | high,vhigh,2,2,med,high,unacc 439 | high,vhigh,2,2,big,low,unacc 440 | high,vhigh,2,2,big,med,unacc 441 | high,vhigh,2,2,big,high,unacc 442 | high,vhigh,2,4,small,low,unacc 443 | high,vhigh,2,4,small,med,unacc 444 | high,vhigh,2,4,small,high,unacc 445 | high,vhigh,2,4,med,low,unacc 446 | high,vhigh,2,4,med,med,unacc 447 | high,vhigh,2,4,med,high,unacc 448 | high,vhigh,2,4,big,low,unacc 449 | high,vhigh,2,4,big,med,unacc 450 | high,vhigh,2,4,big,high,unacc 451 | high,vhigh,2,more,small,low,unacc 452 | high,vhigh,2,more,small,med,unacc 453 | high,vhigh,2,more,small,high,unacc 454 | high,vhigh,2,more,med,low,unacc 455 | high,vhigh,2,more,med,med,unacc 456 | high,vhigh,2,more,med,high,unacc 457 | high,vhigh,2,more,big,low,unacc 458 | high,vhigh,2,more,big,med,unacc 459 | high,vhigh,2,more,big,high,unacc 460 | high,vhigh,3,2,small,low,unacc 461 | high,vhigh,3,2,small,med,unacc 462 | high,vhigh,3,2,small,high,unacc 463 | high,vhigh,3,2,med,low,unacc 464 | high,vhigh,3,2,med,med,unacc 465 | high,vhigh,3,2,med,high,unacc 466 | high,vhigh,3,2,big,low,unacc 467 | high,vhigh,3,2,big,med,unacc 468 | high,vhigh,3,2,big,high,unacc 469 | high,vhigh,3,4,small,low,unacc 470 | high,vhigh,3,4,small,med,unacc 471 | high,vhigh,3,4,small,high,unacc 472 | high,vhigh,3,4,med,low,unacc 473 | high,vhigh,3,4,med,med,unacc 474 | high,vhigh,3,4,med,high,unacc 475 | high,vhigh,3,4,big,low,unacc 476 | high,vhigh,3,4,big,med,unacc 477 | high,vhigh,3,4,big,high,unacc 478 | high,vhigh,3,more,small,low,unacc 479 | high,vhigh,3,more,small,med,unacc 480 | high,vhigh,3,more,small,high,unacc 481 | high,vhigh,3,more,med,low,unacc 482 | high,vhigh,3,more,med,med,unacc 483 | high,vhigh,3,more,med,high,unacc 484 | high,vhigh,3,more,big,low,unacc 485 | high,vhigh,3,more,big,med,unacc 486 | high,vhigh,3,more,big,high,unacc 487 | high,vhigh,4,2,small,low,unacc 488 | high,vhigh,4,2,small,med,unacc 489 | high,vhigh,4,2,small,high,unacc 490 | high,vhigh,4,2,med,low,unacc 491 | high,vhigh,4,2,med,med,unacc 492 | high,vhigh,4,2,med,high,unacc 493 | high,vhigh,4,2,big,low,unacc 494 | high,vhigh,4,2,big,med,unacc 495 | high,vhigh,4,2,big,high,unacc 496 | high,vhigh,4,4,small,low,unacc 497 | high,vhigh,4,4,small,med,unacc 498 | high,vhigh,4,4,small,high,unacc 499 | high,vhigh,4,4,med,low,unacc 500 | high,vhigh,4,4,med,med,unacc 501 | high,vhigh,4,4,med,high,unacc 502 | high,vhigh,4,4,big,low,unacc 503 | high,vhigh,4,4,big,med,unacc 504 | high,vhigh,4,4,big,high,unacc 505 | high,vhigh,4,more,small,low,unacc 506 | high,vhigh,4,more,small,med,unacc 507 | high,vhigh,4,more,small,high,unacc 508 | high,vhigh,4,more,med,low,unacc 509 | high,vhigh,4,more,med,med,unacc 510 | high,vhigh,4,more,med,high,unacc 511 | high,vhigh,4,more,big,low,unacc 512 | high,vhigh,4,more,big,med,unacc 513 | high,vhigh,4,more,big,high,unacc 514 | high,vhigh,5more,2,small,low,unacc 515 | high,vhigh,5more,2,small,med,unacc 516 | high,vhigh,5more,2,small,high,unacc 517 | high,vhigh,5more,2,med,low,unacc 518 | high,vhigh,5more,2,med,med,unacc 519 | high,vhigh,5more,2,med,high,unacc 520 | high,vhigh,5more,2,big,low,unacc 521 | high,vhigh,5more,2,big,med,unacc 522 | high,vhigh,5more,2,big,high,unacc 523 | high,vhigh,5more,4,small,low,unacc 524 | high,vhigh,5more,4,small,med,unacc 525 | high,vhigh,5more,4,small,high,unacc 526 | high,vhigh,5more,4,med,low,unacc 527 | high,vhigh,5more,4,med,med,unacc 528 | high,vhigh,5more,4,med,high,unacc 529 | high,vhigh,5more,4,big,low,unacc 530 | high,vhigh,5more,4,big,med,unacc 531 | high,vhigh,5more,4,big,high,unacc 532 | high,vhigh,5more,more,small,low,unacc 533 | high,vhigh,5more,more,small,med,unacc 534 | high,vhigh,5more,more,small,high,unacc 535 | high,vhigh,5more,more,med,low,unacc 536 | high,vhigh,5more,more,med,med,unacc 537 | high,vhigh,5more,more,med,high,unacc 538 | high,vhigh,5more,more,big,low,unacc 539 | high,vhigh,5more,more,big,med,unacc 540 | high,vhigh,5more,more,big,high,unacc 541 | high,high,2,2,small,low,unacc 542 | high,high,2,2,small,med,unacc 543 | high,high,2,2,small,high,unacc 544 | high,high,2,2,med,low,unacc 545 | high,high,2,2,med,med,unacc 546 | high,high,2,2,med,high,unacc 547 | high,high,2,2,big,low,unacc 548 | high,high,2,2,big,med,unacc 549 | high,high,2,2,big,high,unacc 550 | high,high,2,4,small,low,unacc 551 | high,high,2,4,small,med,unacc 552 | high,high,2,4,small,high,acc 553 | high,high,2,4,med,low,unacc 554 | high,high,2,4,med,med,unacc 555 | high,high,2,4,med,high,acc 556 | high,high,2,4,big,low,unacc 557 | high,high,2,4,big,med,acc 558 | high,high,2,4,big,high,acc 559 | high,high,2,more,small,low,unacc 560 | high,high,2,more,small,med,unacc 561 | high,high,2,more,small,high,unacc 562 | high,high,2,more,med,low,unacc 563 | high,high,2,more,med,med,unacc 564 | high,high,2,more,med,high,acc 565 | high,high,2,more,big,low,unacc 566 | high,high,2,more,big,med,acc 567 | high,high,2,more,big,high,acc 568 | high,high,3,2,small,low,unacc 569 | high,high,3,2,small,med,unacc 570 | high,high,3,2,small,high,unacc 571 | high,high,3,2,med,low,unacc 572 | high,high,3,2,med,med,unacc 573 | high,high,3,2,med,high,unacc 574 | high,high,3,2,big,low,unacc 575 | high,high,3,2,big,med,unacc 576 | high,high,3,2,big,high,unacc 577 | high,high,3,4,small,low,unacc 578 | high,high,3,4,small,med,unacc 579 | high,high,3,4,small,high,acc 580 | high,high,3,4,med,low,unacc 581 | high,high,3,4,med,med,unacc 582 | high,high,3,4,med,high,acc 583 | high,high,3,4,big,low,unacc 584 | high,high,3,4,big,med,acc 585 | high,high,3,4,big,high,acc 586 | high,high,3,more,small,low,unacc 587 | high,high,3,more,small,med,unacc 588 | high,high,3,more,small,high,acc 589 | high,high,3,more,med,low,unacc 590 | high,high,3,more,med,med,acc 591 | high,high,3,more,med,high,acc 592 | high,high,3,more,big,low,unacc 593 | high,high,3,more,big,med,acc 594 | high,high,3,more,big,high,acc 595 | high,high,4,2,small,low,unacc 596 | high,high,4,2,small,med,unacc 597 | high,high,4,2,small,high,unacc 598 | high,high,4,2,med,low,unacc 599 | high,high,4,2,med,med,unacc 600 | high,high,4,2,med,high,unacc 601 | high,high,4,2,big,low,unacc 602 | high,high,4,2,big,med,unacc 603 | high,high,4,2,big,high,unacc 604 | high,high,4,4,small,low,unacc 605 | high,high,4,4,small,med,unacc 606 | high,high,4,4,small,high,acc 607 | high,high,4,4,med,low,unacc 608 | high,high,4,4,med,med,acc 609 | high,high,4,4,med,high,acc 610 | high,high,4,4,big,low,unacc 611 | high,high,4,4,big,med,acc 612 | high,high,4,4,big,high,acc 613 | high,high,4,more,small,low,unacc 614 | high,high,4,more,small,med,unacc 615 | high,high,4,more,small,high,acc 616 | high,high,4,more,med,low,unacc 617 | high,high,4,more,med,med,acc 618 | high,high,4,more,med,high,acc 619 | high,high,4,more,big,low,unacc 620 | high,high,4,more,big,med,acc 621 | high,high,4,more,big,high,acc 622 | high,high,5more,2,small,low,unacc 623 | high,high,5more,2,small,med,unacc 624 | high,high,5more,2,small,high,unacc 625 | high,high,5more,2,med,low,unacc 626 | high,high,5more,2,med,med,unacc 627 | high,high,5more,2,med,high,unacc 628 | high,high,5more,2,big,low,unacc 629 | high,high,5more,2,big,med,unacc 630 | high,high,5more,2,big,high,unacc 631 | high,high,5more,4,small,low,unacc 632 | high,high,5more,4,small,med,unacc 633 | high,high,5more,4,small,high,acc 634 | high,high,5more,4,med,low,unacc 635 | high,high,5more,4,med,med,acc 636 | high,high,5more,4,med,high,acc 637 | high,high,5more,4,big,low,unacc 638 | high,high,5more,4,big,med,acc 639 | high,high,5more,4,big,high,acc 640 | high,high,5more,more,small,low,unacc 641 | high,high,5more,more,small,med,unacc 642 | high,high,5more,more,small,high,acc 643 | high,high,5more,more,med,low,unacc 644 | high,high,5more,more,med,med,acc 645 | high,high,5more,more,med,high,acc 646 | high,high,5more,more,big,low,unacc 647 | high,high,5more,more,big,med,acc 648 | high,high,5more,more,big,high,acc 649 | high,med,2,2,small,low,unacc 650 | high,med,2,2,small,med,unacc 651 | high,med,2,2,small,high,unacc 652 | high,med,2,2,med,low,unacc 653 | high,med,2,2,med,med,unacc 654 | high,med,2,2,med,high,unacc 655 | high,med,2,2,big,low,unacc 656 | high,med,2,2,big,med,unacc 657 | high,med,2,2,big,high,unacc 658 | high,med,2,4,small,low,unacc 659 | high,med,2,4,small,med,unacc 660 | high,med,2,4,small,high,acc 661 | high,med,2,4,med,low,unacc 662 | high,med,2,4,med,med,unacc 663 | high,med,2,4,med,high,acc 664 | high,med,2,4,big,low,unacc 665 | high,med,2,4,big,med,acc 666 | high,med,2,4,big,high,acc 667 | high,med,2,more,small,low,unacc 668 | high,med,2,more,small,med,unacc 669 | high,med,2,more,small,high,unacc 670 | high,med,2,more,med,low,unacc 671 | high,med,2,more,med,med,unacc 672 | high,med,2,more,med,high,acc 673 | high,med,2,more,big,low,unacc 674 | high,med,2,more,big,med,acc 675 | high,med,2,more,big,high,acc 676 | high,med,3,2,small,low,unacc 677 | high,med,3,2,small,med,unacc 678 | high,med,3,2,small,high,unacc 679 | high,med,3,2,med,low,unacc 680 | high,med,3,2,med,med,unacc 681 | high,med,3,2,med,high,unacc 682 | high,med,3,2,big,low,unacc 683 | high,med,3,2,big,med,unacc 684 | high,med,3,2,big,high,unacc 685 | high,med,3,4,small,low,unacc 686 | high,med,3,4,small,med,unacc 687 | high,med,3,4,small,high,acc 688 | high,med,3,4,med,low,unacc 689 | high,med,3,4,med,med,unacc 690 | high,med,3,4,med,high,acc 691 | high,med,3,4,big,low,unacc 692 | high,med,3,4,big,med,acc 693 | high,med,3,4,big,high,acc 694 | high,med,3,more,small,low,unacc 695 | high,med,3,more,small,med,unacc 696 | high,med,3,more,small,high,acc 697 | high,med,3,more,med,low,unacc 698 | high,med,3,more,med,med,acc 699 | high,med,3,more,med,high,acc 700 | high,med,3,more,big,low,unacc 701 | high,med,3,more,big,med,acc 702 | high,med,3,more,big,high,acc 703 | high,med,4,2,small,low,unacc 704 | high,med,4,2,small,med,unacc 705 | high,med,4,2,small,high,unacc 706 | high,med,4,2,med,low,unacc 707 | high,med,4,2,med,med,unacc 708 | high,med,4,2,med,high,unacc 709 | high,med,4,2,big,low,unacc 710 | high,med,4,2,big,med,unacc 711 | high,med,4,2,big,high,unacc 712 | high,med,4,4,small,low,unacc 713 | high,med,4,4,small,med,unacc 714 | high,med,4,4,small,high,acc 715 | high,med,4,4,med,low,unacc 716 | high,med,4,4,med,med,acc 717 | high,med,4,4,med,high,acc 718 | high,med,4,4,big,low,unacc 719 | high,med,4,4,big,med,acc 720 | high,med,4,4,big,high,acc 721 | high,med,4,more,small,low,unacc 722 | high,med,4,more,small,med,unacc 723 | high,med,4,more,small,high,acc 724 | high,med,4,more,med,low,unacc 725 | high,med,4,more,med,med,acc 726 | high,med,4,more,med,high,acc 727 | high,med,4,more,big,low,unacc 728 | high,med,4,more,big,med,acc 729 | high,med,4,more,big,high,acc 730 | high,med,5more,2,small,low,unacc 731 | high,med,5more,2,small,med,unacc 732 | high,med,5more,2,small,high,unacc 733 | high,med,5more,2,med,low,unacc 734 | high,med,5more,2,med,med,unacc 735 | high,med,5more,2,med,high,unacc 736 | high,med,5more,2,big,low,unacc 737 | high,med,5more,2,big,med,unacc 738 | high,med,5more,2,big,high,unacc 739 | high,med,5more,4,small,low,unacc 740 | high,med,5more,4,small,med,unacc 741 | high,med,5more,4,small,high,acc 742 | high,med,5more,4,med,low,unacc 743 | high,med,5more,4,med,med,acc 744 | high,med,5more,4,med,high,acc 745 | high,med,5more,4,big,low,unacc 746 | high,med,5more,4,big,med,acc 747 | high,med,5more,4,big,high,acc 748 | high,med,5more,more,small,low,unacc 749 | high,med,5more,more,small,med,unacc 750 | high,med,5more,more,small,high,acc 751 | high,med,5more,more,med,low,unacc 752 | high,med,5more,more,med,med,acc 753 | high,med,5more,more,med,high,acc 754 | high,med,5more,more,big,low,unacc 755 | high,med,5more,more,big,med,acc 756 | high,med,5more,more,big,high,acc 757 | high,low,2,2,small,low,unacc 758 | high,low,2,2,small,med,unacc 759 | high,low,2,2,small,high,unacc 760 | high,low,2,2,med,low,unacc 761 | high,low,2,2,med,med,unacc 762 | high,low,2,2,med,high,unacc 763 | high,low,2,2,big,low,unacc 764 | high,low,2,2,big,med,unacc 765 | high,low,2,2,big,high,unacc 766 | high,low,2,4,small,low,unacc 767 | high,low,2,4,small,med,unacc 768 | high,low,2,4,small,high,acc 769 | high,low,2,4,med,low,unacc 770 | high,low,2,4,med,med,unacc 771 | high,low,2,4,med,high,acc 772 | high,low,2,4,big,low,unacc 773 | high,low,2,4,big,med,acc 774 | high,low,2,4,big,high,acc 775 | high,low,2,more,small,low,unacc 776 | high,low,2,more,small,med,unacc 777 | high,low,2,more,small,high,unacc 778 | high,low,2,more,med,low,unacc 779 | high,low,2,more,med,med,unacc 780 | high,low,2,more,med,high,acc 781 | high,low,2,more,big,low,unacc 782 | high,low,2,more,big,med,acc 783 | high,low,2,more,big,high,acc 784 | high,low,3,2,small,low,unacc 785 | high,low,3,2,small,med,unacc 786 | high,low,3,2,small,high,unacc 787 | high,low,3,2,med,low,unacc 788 | high,low,3,2,med,med,unacc 789 | high,low,3,2,med,high,unacc 790 | high,low,3,2,big,low,unacc 791 | high,low,3,2,big,med,unacc 792 | high,low,3,2,big,high,unacc 793 | high,low,3,4,small,low,unacc 794 | high,low,3,4,small,med,unacc 795 | high,low,3,4,small,high,acc 796 | high,low,3,4,med,low,unacc 797 | high,low,3,4,med,med,unacc 798 | high,low,3,4,med,high,acc 799 | high,low,3,4,big,low,unacc 800 | high,low,3,4,big,med,acc 801 | high,low,3,4,big,high,acc 802 | high,low,3,more,small,low,unacc 803 | high,low,3,more,small,med,unacc 804 | high,low,3,more,small,high,acc 805 | high,low,3,more,med,low,unacc 806 | high,low,3,more,med,med,acc 807 | high,low,3,more,med,high,acc 808 | high,low,3,more,big,low,unacc 809 | high,low,3,more,big,med,acc 810 | high,low,3,more,big,high,acc 811 | high,low,4,2,small,low,unacc 812 | high,low,4,2,small,med,unacc 813 | high,low,4,2,small,high,unacc 814 | high,low,4,2,med,low,unacc 815 | high,low,4,2,med,med,unacc 816 | high,low,4,2,med,high,unacc 817 | high,low,4,2,big,low,unacc 818 | high,low,4,2,big,med,unacc 819 | high,low,4,2,big,high,unacc 820 | high,low,4,4,small,low,unacc 821 | high,low,4,4,small,med,unacc 822 | high,low,4,4,small,high,acc 823 | high,low,4,4,med,low,unacc 824 | high,low,4,4,med,med,acc 825 | high,low,4,4,med,high,acc 826 | high,low,4,4,big,low,unacc 827 | high,low,4,4,big,med,acc 828 | high,low,4,4,big,high,acc 829 | high,low,4,more,small,low,unacc 830 | high,low,4,more,small,med,unacc 831 | high,low,4,more,small,high,acc 832 | high,low,4,more,med,low,unacc 833 | high,low,4,more,med,med,acc 834 | high,low,4,more,med,high,acc 835 | high,low,4,more,big,low,unacc 836 | high,low,4,more,big,med,acc 837 | high,low,4,more,big,high,acc 838 | high,low,5more,2,small,low,unacc 839 | high,low,5more,2,small,med,unacc 840 | high,low,5more,2,small,high,unacc 841 | high,low,5more,2,med,low,unacc 842 | high,low,5more,2,med,med,unacc 843 | high,low,5more,2,med,high,unacc 844 | high,low,5more,2,big,low,unacc 845 | high,low,5more,2,big,med,unacc 846 | high,low,5more,2,big,high,unacc 847 | high,low,5more,4,small,low,unacc 848 | high,low,5more,4,small,med,unacc 849 | high,low,5more,4,small,high,acc 850 | high,low,5more,4,med,low,unacc 851 | high,low,5more,4,med,med,acc 852 | high,low,5more,4,med,high,acc 853 | high,low,5more,4,big,low,unacc 854 | high,low,5more,4,big,med,acc 855 | high,low,5more,4,big,high,acc 856 | high,low,5more,more,small,low,unacc 857 | high,low,5more,more,small,med,unacc 858 | high,low,5more,more,small,high,acc 859 | high,low,5more,more,med,low,unacc 860 | high,low,5more,more,med,med,acc 861 | high,low,5more,more,med,high,acc 862 | high,low,5more,more,big,low,unacc 863 | high,low,5more,more,big,med,acc 864 | high,low,5more,more,big,high,acc 865 | med,vhigh,2,2,small,low,unacc 866 | med,vhigh,2,2,small,med,unacc 867 | med,vhigh,2,2,small,high,unacc 868 | med,vhigh,2,2,med,low,unacc 869 | med,vhigh,2,2,med,med,unacc 870 | med,vhigh,2,2,med,high,unacc 871 | med,vhigh,2,2,big,low,unacc 872 | med,vhigh,2,2,big,med,unacc 873 | med,vhigh,2,2,big,high,unacc 874 | med,vhigh,2,4,small,low,unacc 875 | med,vhigh,2,4,small,med,unacc 876 | med,vhigh,2,4,small,high,acc 877 | med,vhigh,2,4,med,low,unacc 878 | med,vhigh,2,4,med,med,unacc 879 | med,vhigh,2,4,med,high,acc 880 | med,vhigh,2,4,big,low,unacc 881 | med,vhigh,2,4,big,med,acc 882 | med,vhigh,2,4,big,high,acc 883 | med,vhigh,2,more,small,low,unacc 884 | med,vhigh,2,more,small,med,unacc 885 | med,vhigh,2,more,small,high,unacc 886 | med,vhigh,2,more,med,low,unacc 887 | med,vhigh,2,more,med,med,unacc 888 | med,vhigh,2,more,med,high,acc 889 | med,vhigh,2,more,big,low,unacc 890 | med,vhigh,2,more,big,med,acc 891 | med,vhigh,2,more,big,high,acc 892 | med,vhigh,3,2,small,low,unacc 893 | med,vhigh,3,2,small,med,unacc 894 | med,vhigh,3,2,small,high,unacc 895 | med,vhigh,3,2,med,low,unacc 896 | med,vhigh,3,2,med,med,unacc 897 | med,vhigh,3,2,med,high,unacc 898 | med,vhigh,3,2,big,low,unacc 899 | med,vhigh,3,2,big,med,unacc 900 | med,vhigh,3,2,big,high,unacc 901 | med,vhigh,3,4,small,low,unacc 902 | med,vhigh,3,4,small,med,unacc 903 | med,vhigh,3,4,small,high,acc 904 | med,vhigh,3,4,med,low,unacc 905 | med,vhigh,3,4,med,med,unacc 906 | med,vhigh,3,4,med,high,acc 907 | med,vhigh,3,4,big,low,unacc 908 | med,vhigh,3,4,big,med,acc 909 | med,vhigh,3,4,big,high,acc 910 | med,vhigh,3,more,small,low,unacc 911 | med,vhigh,3,more,small,med,unacc 912 | med,vhigh,3,more,small,high,acc 913 | med,vhigh,3,more,med,low,unacc 914 | med,vhigh,3,more,med,med,acc 915 | med,vhigh,3,more,med,high,acc 916 | med,vhigh,3,more,big,low,unacc 917 | med,vhigh,3,more,big,med,acc 918 | med,vhigh,3,more,big,high,acc 919 | med,vhigh,4,2,small,low,unacc 920 | med,vhigh,4,2,small,med,unacc 921 | med,vhigh,4,2,small,high,unacc 922 | med,vhigh,4,2,med,low,unacc 923 | med,vhigh,4,2,med,med,unacc 924 | med,vhigh,4,2,med,high,unacc 925 | med,vhigh,4,2,big,low,unacc 926 | med,vhigh,4,2,big,med,unacc 927 | med,vhigh,4,2,big,high,unacc 928 | med,vhigh,4,4,small,low,unacc 929 | med,vhigh,4,4,small,med,unacc 930 | med,vhigh,4,4,small,high,acc 931 | med,vhigh,4,4,med,low,unacc 932 | med,vhigh,4,4,med,med,acc 933 | med,vhigh,4,4,med,high,acc 934 | med,vhigh,4,4,big,low,unacc 935 | med,vhigh,4,4,big,med,acc 936 | med,vhigh,4,4,big,high,acc 937 | med,vhigh,4,more,small,low,unacc 938 | med,vhigh,4,more,small,med,unacc 939 | med,vhigh,4,more,small,high,acc 940 | med,vhigh,4,more,med,low,unacc 941 | med,vhigh,4,more,med,med,acc 942 | med,vhigh,4,more,med,high,acc 943 | med,vhigh,4,more,big,low,unacc 944 | med,vhigh,4,more,big,med,acc 945 | med,vhigh,4,more,big,high,acc 946 | med,vhigh,5more,2,small,low,unacc 947 | med,vhigh,5more,2,small,med,unacc 948 | med,vhigh,5more,2,small,high,unacc 949 | med,vhigh,5more,2,med,low,unacc 950 | med,vhigh,5more,2,med,med,unacc 951 | med,vhigh,5more,2,med,high,unacc 952 | med,vhigh,5more,2,big,low,unacc 953 | med,vhigh,5more,2,big,med,unacc 954 | med,vhigh,5more,2,big,high,unacc 955 | med,vhigh,5more,4,small,low,unacc 956 | med,vhigh,5more,4,small,med,unacc 957 | med,vhigh,5more,4,small,high,acc 958 | med,vhigh,5more,4,med,low,unacc 959 | med,vhigh,5more,4,med,med,acc 960 | med,vhigh,5more,4,med,high,acc 961 | med,vhigh,5more,4,big,low,unacc 962 | med,vhigh,5more,4,big,med,acc 963 | med,vhigh,5more,4,big,high,acc 964 | med,vhigh,5more,more,small,low,unacc 965 | med,vhigh,5more,more,small,med,unacc 966 | med,vhigh,5more,more,small,high,acc 967 | med,vhigh,5more,more,med,low,unacc 968 | med,vhigh,5more,more,med,med,acc 969 | med,vhigh,5more,more,med,high,acc 970 | med,vhigh,5more,more,big,low,unacc 971 | med,vhigh,5more,more,big,med,acc 972 | med,vhigh,5more,more,big,high,acc 973 | med,high,2,2,small,low,unacc 974 | med,high,2,2,small,med,unacc 975 | med,high,2,2,small,high,unacc 976 | med,high,2,2,med,low,unacc 977 | med,high,2,2,med,med,unacc 978 | med,high,2,2,med,high,unacc 979 | med,high,2,2,big,low,unacc 980 | med,high,2,2,big,med,unacc 981 | med,high,2,2,big,high,unacc 982 | med,high,2,4,small,low,unacc 983 | med,high,2,4,small,med,unacc 984 | med,high,2,4,small,high,acc 985 | med,high,2,4,med,low,unacc 986 | med,high,2,4,med,med,unacc 987 | med,high,2,4,med,high,acc 988 | med,high,2,4,big,low,unacc 989 | med,high,2,4,big,med,acc 990 | med,high,2,4,big,high,acc 991 | med,high,2,more,small,low,unacc 992 | med,high,2,more,small,med,unacc 993 | med,high,2,more,small,high,unacc 994 | med,high,2,more,med,low,unacc 995 | med,high,2,more,med,med,unacc 996 | med,high,2,more,med,high,acc 997 | med,high,2,more,big,low,unacc 998 | med,high,2,more,big,med,acc 999 | med,high,2,more,big,high,acc 1000 | med,high,3,2,small,low,unacc 1001 | med,high,3,2,small,med,unacc 1002 | med,high,3,2,small,high,unacc 1003 | med,high,3,2,med,low,unacc 1004 | med,high,3,2,med,med,unacc 1005 | med,high,3,2,med,high,unacc 1006 | med,high,3,2,big,low,unacc 1007 | med,high,3,2,big,med,unacc 1008 | med,high,3,2,big,high,unacc 1009 | med,high,3,4,small,low,unacc 1010 | med,high,3,4,small,med,unacc 1011 | med,high,3,4,small,high,acc 1012 | med,high,3,4,med,low,unacc 1013 | med,high,3,4,med,med,unacc 1014 | med,high,3,4,med,high,acc 1015 | med,high,3,4,big,low,unacc 1016 | med,high,3,4,big,med,acc 1017 | med,high,3,4,big,high,acc 1018 | med,high,3,more,small,low,unacc 1019 | med,high,3,more,small,med,unacc 1020 | med,high,3,more,small,high,acc 1021 | med,high,3,more,med,low,unacc 1022 | med,high,3,more,med,med,acc 1023 | med,high,3,more,med,high,acc 1024 | med,high,3,more,big,low,unacc 1025 | med,high,3,more,big,med,acc 1026 | med,high,3,more,big,high,acc 1027 | med,high,4,2,small,low,unacc 1028 | med,high,4,2,small,med,unacc 1029 | med,high,4,2,small,high,unacc 1030 | med,high,4,2,med,low,unacc 1031 | med,high,4,2,med,med,unacc 1032 | med,high,4,2,med,high,unacc 1033 | med,high,4,2,big,low,unacc 1034 | med,high,4,2,big,med,unacc 1035 | med,high,4,2,big,high,unacc 1036 | med,high,4,4,small,low,unacc 1037 | med,high,4,4,small,med,unacc 1038 | med,high,4,4,small,high,acc 1039 | med,high,4,4,med,low,unacc 1040 | med,high,4,4,med,med,acc 1041 | med,high,4,4,med,high,acc 1042 | med,high,4,4,big,low,unacc 1043 | med,high,4,4,big,med,acc 1044 | med,high,4,4,big,high,acc 1045 | med,high,4,more,small,low,unacc 1046 | med,high,4,more,small,med,unacc 1047 | med,high,4,more,small,high,acc 1048 | med,high,4,more,med,low,unacc 1049 | med,high,4,more,med,med,acc 1050 | med,high,4,more,med,high,acc 1051 | med,high,4,more,big,low,unacc 1052 | med,high,4,more,big,med,acc 1053 | med,high,4,more,big,high,acc 1054 | med,high,5more,2,small,low,unacc 1055 | med,high,5more,2,small,med,unacc 1056 | med,high,5more,2,small,high,unacc 1057 | med,high,5more,2,med,low,unacc 1058 | med,high,5more,2,med,med,unacc 1059 | med,high,5more,2,med,high,unacc 1060 | med,high,5more,2,big,low,unacc 1061 | med,high,5more,2,big,med,unacc 1062 | med,high,5more,2,big,high,unacc 1063 | med,high,5more,4,small,low,unacc 1064 | med,high,5more,4,small,med,unacc 1065 | med,high,5more,4,small,high,acc 1066 | med,high,5more,4,med,low,unacc 1067 | med,high,5more,4,med,med,acc 1068 | med,high,5more,4,med,high,acc 1069 | med,high,5more,4,big,low,unacc 1070 | med,high,5more,4,big,med,acc 1071 | med,high,5more,4,big,high,acc 1072 | med,high,5more,more,small,low,unacc 1073 | med,high,5more,more,small,med,unacc 1074 | med,high,5more,more,small,high,acc 1075 | med,high,5more,more,med,low,unacc 1076 | med,high,5more,more,med,med,acc 1077 | med,high,5more,more,med,high,acc 1078 | med,high,5more,more,big,low,unacc 1079 | med,high,5more,more,big,med,acc 1080 | med,high,5more,more,big,high,acc 1081 | med,med,2,2,small,low,unacc 1082 | med,med,2,2,small,med,unacc 1083 | med,med,2,2,small,high,unacc 1084 | med,med,2,2,med,low,unacc 1085 | med,med,2,2,med,med,unacc 1086 | med,med,2,2,med,high,unacc 1087 | med,med,2,2,big,low,unacc 1088 | med,med,2,2,big,med,unacc 1089 | med,med,2,2,big,high,unacc 1090 | med,med,2,4,small,low,unacc 1091 | med,med,2,4,small,med,acc 1092 | med,med,2,4,small,high,acc 1093 | med,med,2,4,med,low,unacc 1094 | med,med,2,4,med,med,acc 1095 | med,med,2,4,med,high,acc 1096 | med,med,2,4,big,low,unacc 1097 | med,med,2,4,big,med,acc 1098 | med,med,2,4,big,high,vgood 1099 | med,med,2,more,small,low,unacc 1100 | med,med,2,more,small,med,unacc 1101 | med,med,2,more,small,high,unacc 1102 | med,med,2,more,med,low,unacc 1103 | med,med,2,more,med,med,acc 1104 | med,med,2,more,med,high,acc 1105 | med,med,2,more,big,low,unacc 1106 | med,med,2,more,big,med,acc 1107 | med,med,2,more,big,high,vgood 1108 | med,med,3,2,small,low,unacc 1109 | med,med,3,2,small,med,unacc 1110 | med,med,3,2,small,high,unacc 1111 | med,med,3,2,med,low,unacc 1112 | med,med,3,2,med,med,unacc 1113 | med,med,3,2,med,high,unacc 1114 | med,med,3,2,big,low,unacc 1115 | med,med,3,2,big,med,unacc 1116 | med,med,3,2,big,high,unacc 1117 | med,med,3,4,small,low,unacc 1118 | med,med,3,4,small,med,acc 1119 | med,med,3,4,small,high,acc 1120 | med,med,3,4,med,low,unacc 1121 | med,med,3,4,med,med,acc 1122 | med,med,3,4,med,high,acc 1123 | med,med,3,4,big,low,unacc 1124 | med,med,3,4,big,med,acc 1125 | med,med,3,4,big,high,vgood 1126 | med,med,3,more,small,low,unacc 1127 | med,med,3,more,small,med,acc 1128 | med,med,3,more,small,high,acc 1129 | med,med,3,more,med,low,unacc 1130 | med,med,3,more,med,med,acc 1131 | med,med,3,more,med,high,vgood 1132 | med,med,3,more,big,low,unacc 1133 | med,med,3,more,big,med,acc 1134 | med,med,3,more,big,high,vgood 1135 | med,med,4,2,small,low,unacc 1136 | med,med,4,2,small,med,unacc 1137 | med,med,4,2,small,high,unacc 1138 | med,med,4,2,med,low,unacc 1139 | med,med,4,2,med,med,unacc 1140 | med,med,4,2,med,high,unacc 1141 | med,med,4,2,big,low,unacc 1142 | med,med,4,2,big,med,unacc 1143 | med,med,4,2,big,high,unacc 1144 | med,med,4,4,small,low,unacc 1145 | med,med,4,4,small,med,acc 1146 | med,med,4,4,small,high,acc 1147 | med,med,4,4,med,low,unacc 1148 | med,med,4,4,med,med,acc 1149 | med,med,4,4,med,high,vgood 1150 | med,med,4,4,big,low,unacc 1151 | med,med,4,4,big,med,acc 1152 | med,med,4,4,big,high,vgood 1153 | med,med,4,more,small,low,unacc 1154 | med,med,4,more,small,med,acc 1155 | med,med,4,more,small,high,acc 1156 | med,med,4,more,med,low,unacc 1157 | med,med,4,more,med,med,acc 1158 | med,med,4,more,med,high,vgood 1159 | med,med,4,more,big,low,unacc 1160 | med,med,4,more,big,med,acc 1161 | med,med,4,more,big,high,vgood 1162 | med,med,5more,2,small,low,unacc 1163 | med,med,5more,2,small,med,unacc 1164 | med,med,5more,2,small,high,unacc 1165 | med,med,5more,2,med,low,unacc 1166 | med,med,5more,2,med,med,unacc 1167 | med,med,5more,2,med,high,unacc 1168 | med,med,5more,2,big,low,unacc 1169 | med,med,5more,2,big,med,unacc 1170 | med,med,5more,2,big,high,unacc 1171 | med,med,5more,4,small,low,unacc 1172 | med,med,5more,4,small,med,acc 1173 | med,med,5more,4,small,high,acc 1174 | med,med,5more,4,med,low,unacc 1175 | med,med,5more,4,med,med,acc 1176 | med,med,5more,4,med,high,vgood 1177 | med,med,5more,4,big,low,unacc 1178 | med,med,5more,4,big,med,acc 1179 | med,med,5more,4,big,high,vgood 1180 | med,med,5more,more,small,low,unacc 1181 | med,med,5more,more,small,med,acc 1182 | med,med,5more,more,small,high,acc 1183 | med,med,5more,more,med,low,unacc 1184 | med,med,5more,more,med,med,acc 1185 | med,med,5more,more,med,high,vgood 1186 | med,med,5more,more,big,low,unacc 1187 | med,med,5more,more,big,med,acc 1188 | med,med,5more,more,big,high,vgood 1189 | med,low,2,2,small,low,unacc 1190 | med,low,2,2,small,med,unacc 1191 | med,low,2,2,small,high,unacc 1192 | med,low,2,2,med,low,unacc 1193 | med,low,2,2,med,med,unacc 1194 | med,low,2,2,med,high,unacc 1195 | med,low,2,2,big,low,unacc 1196 | med,low,2,2,big,med,unacc 1197 | med,low,2,2,big,high,unacc 1198 | med,low,2,4,small,low,unacc 1199 | med,low,2,4,small,med,acc 1200 | med,low,2,4,small,high,good 1201 | med,low,2,4,med,low,unacc 1202 | med,low,2,4,med,med,acc 1203 | med,low,2,4,med,high,good 1204 | med,low,2,4,big,low,unacc 1205 | med,low,2,4,big,med,good 1206 | med,low,2,4,big,high,vgood 1207 | med,low,2,more,small,low,unacc 1208 | med,low,2,more,small,med,unacc 1209 | med,low,2,more,small,high,unacc 1210 | med,low,2,more,med,low,unacc 1211 | med,low,2,more,med,med,acc 1212 | med,low,2,more,med,high,good 1213 | med,low,2,more,big,low,unacc 1214 | med,low,2,more,big,med,good 1215 | med,low,2,more,big,high,vgood 1216 | med,low,3,2,small,low,unacc 1217 | med,low,3,2,small,med,unacc 1218 | med,low,3,2,small,high,unacc 1219 | med,low,3,2,med,low,unacc 1220 | med,low,3,2,med,med,unacc 1221 | med,low,3,2,med,high,unacc 1222 | med,low,3,2,big,low,unacc 1223 | med,low,3,2,big,med,unacc 1224 | med,low,3,2,big,high,unacc 1225 | med,low,3,4,small,low,unacc 1226 | med,low,3,4,small,med,acc 1227 | med,low,3,4,small,high,good 1228 | med,low,3,4,med,low,unacc 1229 | med,low,3,4,med,med,acc 1230 | med,low,3,4,med,high,good 1231 | med,low,3,4,big,low,unacc 1232 | med,low,3,4,big,med,good 1233 | med,low,3,4,big,high,vgood 1234 | med,low,3,more,small,low,unacc 1235 | med,low,3,more,small,med,acc 1236 | med,low,3,more,small,high,good 1237 | med,low,3,more,med,low,unacc 1238 | med,low,3,more,med,med,good 1239 | med,low,3,more,med,high,vgood 1240 | med,low,3,more,big,low,unacc 1241 | med,low,3,more,big,med,good 1242 | med,low,3,more,big,high,vgood 1243 | med,low,4,2,small,low,unacc 1244 | med,low,4,2,small,med,unacc 1245 | med,low,4,2,small,high,unacc 1246 | med,low,4,2,med,low,unacc 1247 | med,low,4,2,med,med,unacc 1248 | med,low,4,2,med,high,unacc 1249 | med,low,4,2,big,low,unacc 1250 | med,low,4,2,big,med,unacc 1251 | med,low,4,2,big,high,unacc 1252 | med,low,4,4,small,low,unacc 1253 | med,low,4,4,small,med,acc 1254 | med,low,4,4,small,high,good 1255 | med,low,4,4,med,low,unacc 1256 | med,low,4,4,med,med,good 1257 | med,low,4,4,med,high,vgood 1258 | med,low,4,4,big,low,unacc 1259 | med,low,4,4,big,med,good 1260 | med,low,4,4,big,high,vgood 1261 | med,low,4,more,small,low,unacc 1262 | med,low,4,more,small,med,acc 1263 | med,low,4,more,small,high,good 1264 | med,low,4,more,med,low,unacc 1265 | med,low,4,more,med,med,good 1266 | med,low,4,more,med,high,vgood 1267 | med,low,4,more,big,low,unacc 1268 | med,low,4,more,big,med,good 1269 | med,low,4,more,big,high,vgood 1270 | med,low,5more,2,small,low,unacc 1271 | med,low,5more,2,small,med,unacc 1272 | med,low,5more,2,small,high,unacc 1273 | med,low,5more,2,med,low,unacc 1274 | med,low,5more,2,med,med,unacc 1275 | med,low,5more,2,med,high,unacc 1276 | med,low,5more,2,big,low,unacc 1277 | med,low,5more,2,big,med,unacc 1278 | med,low,5more,2,big,high,unacc 1279 | med,low,5more,4,small,low,unacc 1280 | med,low,5more,4,small,med,acc 1281 | med,low,5more,4,small,high,good 1282 | med,low,5more,4,med,low,unacc 1283 | med,low,5more,4,med,med,good 1284 | med,low,5more,4,med,high,vgood 1285 | med,low,5more,4,big,low,unacc 1286 | med,low,5more,4,big,med,good 1287 | med,low,5more,4,big,high,vgood 1288 | med,low,5more,more,small,low,unacc 1289 | med,low,5more,more,small,med,acc 1290 | med,low,5more,more,small,high,good 1291 | med,low,5more,more,med,low,unacc 1292 | med,low,5more,more,med,med,good 1293 | med,low,5more,more,med,high,vgood 1294 | med,low,5more,more,big,low,unacc 1295 | med,low,5more,more,big,med,good 1296 | med,low,5more,more,big,high,vgood 1297 | low,vhigh,2,2,small,low,unacc 1298 | low,vhigh,2,2,small,med,unacc 1299 | low,vhigh,2,2,small,high,unacc 1300 | low,vhigh,2,2,med,low,unacc 1301 | low,vhigh,2,2,med,med,unacc 1302 | low,vhigh,2,2,med,high,unacc 1303 | low,vhigh,2,2,big,low,unacc 1304 | low,vhigh,2,2,big,med,unacc 1305 | low,vhigh,2,2,big,high,unacc 1306 | low,vhigh,2,4,small,low,unacc 1307 | low,vhigh,2,4,small,med,unacc 1308 | low,vhigh,2,4,small,high,acc 1309 | low,vhigh,2,4,med,low,unacc 1310 | low,vhigh,2,4,med,med,unacc 1311 | low,vhigh,2,4,med,high,acc 1312 | low,vhigh,2,4,big,low,unacc 1313 | low,vhigh,2,4,big,med,acc 1314 | low,vhigh,2,4,big,high,acc 1315 | low,vhigh,2,more,small,low,unacc 1316 | low,vhigh,2,more,small,med,unacc 1317 | low,vhigh,2,more,small,high,unacc 1318 | low,vhigh,2,more,med,low,unacc 1319 | low,vhigh,2,more,med,med,unacc 1320 | low,vhigh,2,more,med,high,acc 1321 | low,vhigh,2,more,big,low,unacc 1322 | low,vhigh,2,more,big,med,acc 1323 | low,vhigh,2,more,big,high,acc 1324 | low,vhigh,3,2,small,low,unacc 1325 | low,vhigh,3,2,small,med,unacc 1326 | low,vhigh,3,2,small,high,unacc 1327 | low,vhigh,3,2,med,low,unacc 1328 | low,vhigh,3,2,med,med,unacc 1329 | low,vhigh,3,2,med,high,unacc 1330 | low,vhigh,3,2,big,low,unacc 1331 | low,vhigh,3,2,big,med,unacc 1332 | low,vhigh,3,2,big,high,unacc 1333 | low,vhigh,3,4,small,low,unacc 1334 | low,vhigh,3,4,small,med,unacc 1335 | low,vhigh,3,4,small,high,acc 1336 | low,vhigh,3,4,med,low,unacc 1337 | low,vhigh,3,4,med,med,unacc 1338 | low,vhigh,3,4,med,high,acc 1339 | low,vhigh,3,4,big,low,unacc 1340 | low,vhigh,3,4,big,med,acc 1341 | low,vhigh,3,4,big,high,acc 1342 | low,vhigh,3,more,small,low,unacc 1343 | low,vhigh,3,more,small,med,unacc 1344 | low,vhigh,3,more,small,high,acc 1345 | low,vhigh,3,more,med,low,unacc 1346 | low,vhigh,3,more,med,med,acc 1347 | low,vhigh,3,more,med,high,acc 1348 | low,vhigh,3,more,big,low,unacc 1349 | low,vhigh,3,more,big,med,acc 1350 | low,vhigh,3,more,big,high,acc 1351 | low,vhigh,4,2,small,low,unacc 1352 | low,vhigh,4,2,small,med,unacc 1353 | low,vhigh,4,2,small,high,unacc 1354 | low,vhigh,4,2,med,low,unacc 1355 | low,vhigh,4,2,med,med,unacc 1356 | low,vhigh,4,2,med,high,unacc 1357 | low,vhigh,4,2,big,low,unacc 1358 | low,vhigh,4,2,big,med,unacc 1359 | low,vhigh,4,2,big,high,unacc 1360 | low,vhigh,4,4,small,low,unacc 1361 | low,vhigh,4,4,small,med,unacc 1362 | low,vhigh,4,4,small,high,acc 1363 | low,vhigh,4,4,med,low,unacc 1364 | low,vhigh,4,4,med,med,acc 1365 | low,vhigh,4,4,med,high,acc 1366 | low,vhigh,4,4,big,low,unacc 1367 | low,vhigh,4,4,big,med,acc 1368 | low,vhigh,4,4,big,high,acc 1369 | low,vhigh,4,more,small,low,unacc 1370 | low,vhigh,4,more,small,med,unacc 1371 | low,vhigh,4,more,small,high,acc 1372 | low,vhigh,4,more,med,low,unacc 1373 | low,vhigh,4,more,med,med,acc 1374 | low,vhigh,4,more,med,high,acc 1375 | low,vhigh,4,more,big,low,unacc 1376 | low,vhigh,4,more,big,med,acc 1377 | low,vhigh,4,more,big,high,acc 1378 | low,vhigh,5more,2,small,low,unacc 1379 | low,vhigh,5more,2,small,med,unacc 1380 | low,vhigh,5more,2,small,high,unacc 1381 | low,vhigh,5more,2,med,low,unacc 1382 | low,vhigh,5more,2,med,med,unacc 1383 | low,vhigh,5more,2,med,high,unacc 1384 | low,vhigh,5more,2,big,low,unacc 1385 | low,vhigh,5more,2,big,med,unacc 1386 | low,vhigh,5more,2,big,high,unacc 1387 | low,vhigh,5more,4,small,low,unacc 1388 | low,vhigh,5more,4,small,med,unacc 1389 | low,vhigh,5more,4,small,high,acc 1390 | low,vhigh,5more,4,med,low,unacc 1391 | low,vhigh,5more,4,med,med,acc 1392 | low,vhigh,5more,4,med,high,acc 1393 | low,vhigh,5more,4,big,low,unacc 1394 | low,vhigh,5more,4,big,med,acc 1395 | low,vhigh,5more,4,big,high,acc 1396 | low,vhigh,5more,more,small,low,unacc 1397 | low,vhigh,5more,more,small,med,unacc 1398 | low,vhigh,5more,more,small,high,acc 1399 | low,vhigh,5more,more,med,low,unacc 1400 | low,vhigh,5more,more,med,med,acc 1401 | low,vhigh,5more,more,med,high,acc 1402 | low,vhigh,5more,more,big,low,unacc 1403 | low,vhigh,5more,more,big,med,acc 1404 | low,vhigh,5more,more,big,high,acc 1405 | low,high,2,2,small,low,unacc 1406 | low,high,2,2,small,med,unacc 1407 | low,high,2,2,small,high,unacc 1408 | low,high,2,2,med,low,unacc 1409 | low,high,2,2,med,med,unacc 1410 | low,high,2,2,med,high,unacc 1411 | low,high,2,2,big,low,unacc 1412 | low,high,2,2,big,med,unacc 1413 | low,high,2,2,big,high,unacc 1414 | low,high,2,4,small,low,unacc 1415 | low,high,2,4,small,med,acc 1416 | low,high,2,4,small,high,acc 1417 | low,high,2,4,med,low,unacc 1418 | low,high,2,4,med,med,acc 1419 | low,high,2,4,med,high,acc 1420 | low,high,2,4,big,low,unacc 1421 | low,high,2,4,big,med,acc 1422 | low,high,2,4,big,high,vgood 1423 | low,high,2,more,small,low,unacc 1424 | low,high,2,more,small,med,unacc 1425 | low,high,2,more,small,high,unacc 1426 | low,high,2,more,med,low,unacc 1427 | low,high,2,more,med,med,acc 1428 | low,high,2,more,med,high,acc 1429 | low,high,2,more,big,low,unacc 1430 | low,high,2,more,big,med,acc 1431 | low,high,2,more,big,high,vgood 1432 | low,high,3,2,small,low,unacc 1433 | low,high,3,2,small,med,unacc 1434 | low,high,3,2,small,high,unacc 1435 | low,high,3,2,med,low,unacc 1436 | low,high,3,2,med,med,unacc 1437 | low,high,3,2,med,high,unacc 1438 | low,high,3,2,big,low,unacc 1439 | low,high,3,2,big,med,unacc 1440 | low,high,3,2,big,high,unacc 1441 | low,high,3,4,small,low,unacc 1442 | low,high,3,4,small,med,acc 1443 | low,high,3,4,small,high,acc 1444 | low,high,3,4,med,low,unacc 1445 | low,high,3,4,med,med,acc 1446 | low,high,3,4,med,high,acc 1447 | low,high,3,4,big,low,unacc 1448 | low,high,3,4,big,med,acc 1449 | low,high,3,4,big,high,vgood 1450 | low,high,3,more,small,low,unacc 1451 | low,high,3,more,small,med,acc 1452 | low,high,3,more,small,high,acc 1453 | low,high,3,more,med,low,unacc 1454 | low,high,3,more,med,med,acc 1455 | low,high,3,more,med,high,vgood 1456 | low,high,3,more,big,low,unacc 1457 | low,high,3,more,big,med,acc 1458 | low,high,3,more,big,high,vgood 1459 | low,high,4,2,small,low,unacc 1460 | low,high,4,2,small,med,unacc 1461 | low,high,4,2,small,high,unacc 1462 | low,high,4,2,med,low,unacc 1463 | low,high,4,2,med,med,unacc 1464 | low,high,4,2,med,high,unacc 1465 | low,high,4,2,big,low,unacc 1466 | low,high,4,2,big,med,unacc 1467 | low,high,4,2,big,high,unacc 1468 | low,high,4,4,small,low,unacc 1469 | low,high,4,4,small,med,acc 1470 | low,high,4,4,small,high,acc 1471 | low,high,4,4,med,low,unacc 1472 | low,high,4,4,med,med,acc 1473 | low,high,4,4,med,high,vgood 1474 | low,high,4,4,big,low,unacc 1475 | low,high,4,4,big,med,acc 1476 | low,high,4,4,big,high,vgood 1477 | low,high,4,more,small,low,unacc 1478 | low,high,4,more,small,med,acc 1479 | low,high,4,more,small,high,acc 1480 | low,high,4,more,med,low,unacc 1481 | low,high,4,more,med,med,acc 1482 | low,high,4,more,med,high,vgood 1483 | low,high,4,more,big,low,unacc 1484 | low,high,4,more,big,med,acc 1485 | low,high,4,more,big,high,vgood 1486 | low,high,5more,2,small,low,unacc 1487 | low,high,5more,2,small,med,unacc 1488 | low,high,5more,2,small,high,unacc 1489 | low,high,5more,2,med,low,unacc 1490 | low,high,5more,2,med,med,unacc 1491 | low,high,5more,2,med,high,unacc 1492 | low,high,5more,2,big,low,unacc 1493 | low,high,5more,2,big,med,unacc 1494 | low,high,5more,2,big,high,unacc 1495 | low,high,5more,4,small,low,unacc 1496 | low,high,5more,4,small,med,acc 1497 | low,high,5more,4,small,high,acc 1498 | low,high,5more,4,med,low,unacc 1499 | low,high,5more,4,med,med,acc 1500 | low,high,5more,4,med,high,vgood 1501 | low,high,5more,4,big,low,unacc 1502 | low,high,5more,4,big,med,acc 1503 | low,high,5more,4,big,high,vgood 1504 | low,high,5more,more,small,low,unacc 1505 | low,high,5more,more,small,med,acc 1506 | low,high,5more,more,small,high,acc 1507 | low,high,5more,more,med,low,unacc 1508 | low,high,5more,more,med,med,acc 1509 | low,high,5more,more,med,high,vgood 1510 | low,high,5more,more,big,low,unacc 1511 | low,high,5more,more,big,med,acc 1512 | low,high,5more,more,big,high,vgood 1513 | low,med,2,2,small,low,unacc 1514 | low,med,2,2,small,med,unacc 1515 | low,med,2,2,small,high,unacc 1516 | low,med,2,2,med,low,unacc 1517 | low,med,2,2,med,med,unacc 1518 | low,med,2,2,med,high,unacc 1519 | low,med,2,2,big,low,unacc 1520 | low,med,2,2,big,med,unacc 1521 | low,med,2,2,big,high,unacc 1522 | low,med,2,4,small,low,unacc 1523 | low,med,2,4,small,med,acc 1524 | low,med,2,4,small,high,good 1525 | low,med,2,4,med,low,unacc 1526 | low,med,2,4,med,med,acc 1527 | low,med,2,4,med,high,good 1528 | low,med,2,4,big,low,unacc 1529 | low,med,2,4,big,med,good 1530 | low,med,2,4,big,high,vgood 1531 | low,med,2,more,small,low,unacc 1532 | low,med,2,more,small,med,unacc 1533 | low,med,2,more,small,high,unacc 1534 | low,med,2,more,med,low,unacc 1535 | low,med,2,more,med,med,acc 1536 | low,med,2,more,med,high,good 1537 | low,med,2,more,big,low,unacc 1538 | low,med,2,more,big,med,good 1539 | low,med,2,more,big,high,vgood 1540 | low,med,3,2,small,low,unacc 1541 | low,med,3,2,small,med,unacc 1542 | low,med,3,2,small,high,unacc 1543 | low,med,3,2,med,low,unacc 1544 | low,med,3,2,med,med,unacc 1545 | low,med,3,2,med,high,unacc 1546 | low,med,3,2,big,low,unacc 1547 | low,med,3,2,big,med,unacc 1548 | low,med,3,2,big,high,unacc 1549 | low,med,3,4,small,low,unacc 1550 | low,med,3,4,small,med,acc 1551 | low,med,3,4,small,high,good 1552 | low,med,3,4,med,low,unacc 1553 | low,med,3,4,med,med,acc 1554 | low,med,3,4,med,high,good 1555 | low,med,3,4,big,low,unacc 1556 | low,med,3,4,big,med,good 1557 | low,med,3,4,big,high,vgood 1558 | low,med,3,more,small,low,unacc 1559 | low,med,3,more,small,med,acc 1560 | low,med,3,more,small,high,good 1561 | low,med,3,more,med,low,unacc 1562 | low,med,3,more,med,med,good 1563 | low,med,3,more,med,high,vgood 1564 | low,med,3,more,big,low,unacc 1565 | low,med,3,more,big,med,good 1566 | low,med,3,more,big,high,vgood 1567 | low,med,4,2,small,low,unacc 1568 | low,med,4,2,small,med,unacc 1569 | low,med,4,2,small,high,unacc 1570 | low,med,4,2,med,low,unacc 1571 | low,med,4,2,med,med,unacc 1572 | low,med,4,2,med,high,unacc 1573 | low,med,4,2,big,low,unacc 1574 | low,med,4,2,big,med,unacc 1575 | low,med,4,2,big,high,unacc 1576 | low,med,4,4,small,low,unacc 1577 | low,med,4,4,small,med,acc 1578 | low,med,4,4,small,high,good 1579 | low,med,4,4,med,low,unacc 1580 | low,med,4,4,med,med,good 1581 | low,med,4,4,med,high,vgood 1582 | low,med,4,4,big,low,unacc 1583 | low,med,4,4,big,med,good 1584 | low,med,4,4,big,high,vgood 1585 | low,med,4,more,small,low,unacc 1586 | low,med,4,more,small,med,acc 1587 | low,med,4,more,small,high,good 1588 | low,med,4,more,med,low,unacc 1589 | low,med,4,more,med,med,good 1590 | low,med,4,more,med,high,vgood 1591 | low,med,4,more,big,low,unacc 1592 | low,med,4,more,big,med,good 1593 | low,med,4,more,big,high,vgood 1594 | low,med,5more,2,small,low,unacc 1595 | low,med,5more,2,small,med,unacc 1596 | low,med,5more,2,small,high,unacc 1597 | low,med,5more,2,med,low,unacc 1598 | low,med,5more,2,med,med,unacc 1599 | low,med,5more,2,med,high,unacc 1600 | low,med,5more,2,big,low,unacc 1601 | low,med,5more,2,big,med,unacc 1602 | low,med,5more,2,big,high,unacc 1603 | low,med,5more,4,small,low,unacc 1604 | low,med,5more,4,small,med,acc 1605 | low,med,5more,4,small,high,good 1606 | low,med,5more,4,med,low,unacc 1607 | low,med,5more,4,med,med,good 1608 | low,med,5more,4,med,high,vgood 1609 | low,med,5more,4,big,low,unacc 1610 | low,med,5more,4,big,med,good 1611 | low,med,5more,4,big,high,vgood 1612 | low,med,5more,more,small,low,unacc 1613 | low,med,5more,more,small,med,acc 1614 | low,med,5more,more,small,high,good 1615 | low,med,5more,more,med,low,unacc 1616 | low,med,5more,more,med,med,good 1617 | low,med,5more,more,med,high,vgood 1618 | low,med,5more,more,big,low,unacc 1619 | low,med,5more,more,big,med,good 1620 | low,med,5more,more,big,high,vgood 1621 | low,low,2,2,small,low,unacc 1622 | low,low,2,2,small,med,unacc 1623 | low,low,2,2,small,high,unacc 1624 | low,low,2,2,med,low,unacc 1625 | low,low,2,2,med,med,unacc 1626 | low,low,2,2,med,high,unacc 1627 | low,low,2,2,big,low,unacc 1628 | low,low,2,2,big,med,unacc 1629 | low,low,2,2,big,high,unacc 1630 | low,low,2,4,small,low,unacc 1631 | low,low,2,4,small,med,acc 1632 | low,low,2,4,small,high,good 1633 | low,low,2,4,med,low,unacc 1634 | low,low,2,4,med,med,acc 1635 | low,low,2,4,med,high,good 1636 | low,low,2,4,big,low,unacc 1637 | low,low,2,4,big,med,good 1638 | low,low,2,4,big,high,vgood 1639 | low,low,2,more,small,low,unacc 1640 | low,low,2,more,small,med,unacc 1641 | low,low,2,more,small,high,unacc 1642 | low,low,2,more,med,low,unacc 1643 | low,low,2,more,med,med,acc 1644 | low,low,2,more,med,high,good 1645 | low,low,2,more,big,low,unacc 1646 | low,low,2,more,big,med,good 1647 | low,low,2,more,big,high,vgood 1648 | low,low,3,2,small,low,unacc 1649 | low,low,3,2,small,med,unacc 1650 | low,low,3,2,small,high,unacc 1651 | low,low,3,2,med,low,unacc 1652 | low,low,3,2,med,med,unacc 1653 | low,low,3,2,med,high,unacc 1654 | low,low,3,2,big,low,unacc 1655 | low,low,3,2,big,med,unacc 1656 | low,low,3,2,big,high,unacc 1657 | low,low,3,4,small,low,unacc 1658 | low,low,3,4,small,med,acc 1659 | low,low,3,4,small,high,good 1660 | low,low,3,4,med,low,unacc 1661 | low,low,3,4,med,med,acc 1662 | low,low,3,4,med,high,good 1663 | low,low,3,4,big,low,unacc 1664 | low,low,3,4,big,med,good 1665 | low,low,3,4,big,high,vgood 1666 | low,low,3,more,small,low,unacc 1667 | low,low,3,more,small,med,acc 1668 | low,low,3,more,small,high,good 1669 | low,low,3,more,med,low,unacc 1670 | low,low,3,more,med,med,good 1671 | low,low,3,more,med,high,vgood 1672 | low,low,3,more,big,low,unacc 1673 | low,low,3,more,big,med,good 1674 | low,low,3,more,big,high,vgood 1675 | low,low,4,2,small,low,unacc 1676 | low,low,4,2,small,med,unacc 1677 | low,low,4,2,small,high,unacc 1678 | low,low,4,2,med,low,unacc 1679 | low,low,4,2,med,med,unacc 1680 | low,low,4,2,med,high,unacc 1681 | low,low,4,2,big,low,unacc 1682 | low,low,4,2,big,med,unacc 1683 | low,low,4,2,big,high,unacc 1684 | low,low,4,4,small,low,unacc 1685 | low,low,4,4,small,med,acc 1686 | low,low,4,4,small,high,good 1687 | low,low,4,4,med,low,unacc 1688 | low,low,4,4,med,med,good 1689 | low,low,4,4,med,high,vgood 1690 | low,low,4,4,big,low,unacc 1691 | low,low,4,4,big,med,good 1692 | low,low,4,4,big,high,vgood 1693 | low,low,4,more,small,low,unacc 1694 | low,low,4,more,small,med,acc 1695 | low,low,4,more,small,high,good 1696 | low,low,4,more,med,low,unacc 1697 | low,low,4,more,med,med,good 1698 | low,low,4,more,med,high,vgood 1699 | low,low,4,more,big,low,unacc 1700 | low,low,4,more,big,med,good 1701 | low,low,4,more,big,high,vgood 1702 | low,low,5more,2,small,low,unacc 1703 | low,low,5more,2,small,med,unacc 1704 | low,low,5more,2,small,high,unacc 1705 | low,low,5more,2,med,low,unacc 1706 | low,low,5more,2,med,med,unacc 1707 | low,low,5more,2,med,high,unacc 1708 | low,low,5more,2,big,low,unacc 1709 | low,low,5more,2,big,med,unacc 1710 | low,low,5more,2,big,high,unacc 1711 | low,low,5more,4,small,low,unacc 1712 | low,low,5more,4,small,med,acc 1713 | low,low,5more,4,small,high,good 1714 | low,low,5more,4,med,low,unacc 1715 | low,low,5more,4,med,med,good 1716 | low,low,5more,4,med,high,vgood 1717 | low,low,5more,4,big,low,unacc 1718 | low,low,5more,4,big,med,good 1719 | low,low,5more,4,big,high,vgood 1720 | low,low,5more,more,small,low,unacc 1721 | low,low,5more,more,small,med,acc 1722 | low,low,5more,more,small,high,good 1723 | low,low,5more,more,med,low,unacc 1724 | low,low,5more,more,med,med,good 1725 | low,low,5more,more,med,high,vgood 1726 | low,low,5more,more,big,low,unacc 1727 | low,low,5more,more,big,med,good 1728 | low,low,5more,more,big,high,vgood --------------------------------------------------------------------------------