top of page

Search Results

Search this site

963 results found with an empty search

  • Food Ordering App

    INTRODUCTION : - Food Ordering apps are a new rage, from restaurant owners making their own food ordering app for you to deliver food while sitting on your couch to services like zomato, foodpanda, swiggy which act as a collaboration platform between the restaurants and clients. Building a mobile app is easy with the advent of so many tools and technologies, but depending on the kind of app that you’re building, you may need to follow certain guidelines and adhere to some criteria. Food ordering app development is not a linear process, but one that entails a lot of complexity. Research Findings UX (user experience) research is the systematic investigation of users and their requirements, in order to add context and insight into the process of designing the user experience. UX research employs a variety of techniques, tools, and methodologies to reach conclusions, determine facts, and uncover problems, thereby revealing valuable information that can be fed into the design process. User Personas A user persona is a representation of the goals and behavior of a hypothesized group of users. In most cases, personas are synthesized from data collected from interviews with users. Empathy Mapping An Empathy map will help you understand your user’s needs while you develop a deeper understanding of the persons you are designing for. An Empathy Map is just one tool that can help you empathize and synthesize your observations from the research phase, and draw out unexpected insights about your user’s needs. Scenario and storyboard A scenario is a situation that captures how users perform tasks on your site or app. A storyboard is a visual representation of how the user would react with your site or app. Wireframing A wireframe is a low-fidelity, simplified outline of your product. Wireframes are used early in the development process to establish the basic structure of an app before visual design and content is added. In the ideation phase I created wireframes presenting information architecture of the future layout. App user interface design A mobile user interface (mobile UI) is the graphical and usually touch-sensitive display on a mobile device, such as a smartphone or tablet that allows the user to interact with the device’s apps, features, content, and functions. Development After the successful completion of the design part, development was required in order to bring the project to life. Our Android and iOS developers stepped in and provided their best advice on the design and workflow which made the app flawless as it is today. The client received a huge applaud on the design of the project and is satisfied with our services in totality. Problem Definition The mobile aggregator is an application that combines various thematic platforms in order to increase their level of sales and ensure the convenience of the choice of dishes and drinks by users. A distinctive feature of the application is a single design, user-friendly interface. I decided to create competing app where to make an order should be as simple as few clicks on mobile device. And it should be easy to understand and informative about the options and choices the users have. Process I’ve started the process with competitive research and I identified top three competitors. Analyzing and comparing the content of their apps helped me to determine the direction of development. Further, to build empathy with users, I started off with a set of casual interviews. This resulted in a preliminary set of requirements and creating User Personas Interviews helped me to discover list of main requests of the users: • Quality of the service • Good choice of listed restaurants • Delivery/Take away option • Price criterion • Reviews of other users Wireframes How does our food delivery system work for Restaurant? Step 1: Using a customer mobile app, your customers browse your food menu on the smartphone. They select items & quantity to make a food order & pay for the order via mobile app. Upon payment confirmation, they redirected to order confirmation information and now they can track the order from their account. Tracking tree of the order shows all the information like Order received by the restaurant, Order is in preparation, order ready for delivery, order picked up by driver & confirmation on the delivery of the order. Step 2: After order confirmation, Order goes into Order management tablet app which generally placed at the cash counter of a restaurant or in the kitchen. Staff can accept or deny the order with a note. Order management app has two options – Automatic print of new order via wireless thermal printer or can manually print the order via the wireless thermal printer. As soon as the staff accepts the order, it also goes automatically to the nearest available delivery boy which has been signed up with the system. Step 3: During the preparation of the food, Restaurant staff can assign order delivery to the nearest available delivery guy manually or the delivery guy sees the order in his delivery guy app and can assign himself to deliver the order. Step 4: Delivery boy reaches the restaurant and picks the order for delivery to the customer given address. Customers can see live movements of the delivery boy with an estimated time of arrival on the map interface. Step 5: Order will be delivered to customer address and driver mark delivery completion on their delivery guy mobile app. CONCLUSION : - Taking into account all the mentioned details, we can make the conclusion that the food ordering app development requires a professional workforce, time and resources. Careful planning and learning your users’ needs clarifies a lot of important cornerstones. The point is that you need to target not only the clients but restaurants and couriers as well. Covering all their needs is the proven business strategy that focuses on how to make a food ordering app that can become a successful market competitor. An online food ordering system has been a great way to build brands and strengthen businesses. Thus, no exaggeration to conclude that food ordering and delivery has come a long way since its outset and keeps on growing with its features it keeps adding on with every passing day. Hire Figma Experts for any kind of projects – urgent bug fixes, minor enhancement, full time and part time projects, If you need any type project hep, Our expert will help you start designing immediately. Contact us T H A N K Y O U ! !

  • Disease Detection in Plants.

    We will implement Keras to make this program. Keras is a deep learning API written in Python, running on top of the machine learning platform TensorFlow. It was developed with a focus on enabling fast experimentation. Keras follows best practices for reducing cognitive load: it offers consistent & simple APIs, it minimises the number of user actions required for common use cases, and it provides clear & actionable error messages. It also has extensive documentation and developer guides. First we will import all the important libraries and the data set CIFAR-10 from tensorflow.datasets.The CIFAR-10 dataset consists of 60000 32x32 colour images in 10 classes, with 6000 images per class. There are 50000 training images and 10000 test images. from tensorflow.keras.datasets import cifar10 from tensorflow.keras.preprocessing.image import ImageDataGenerator from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Dense, Dropout, Activation, Flatten from tensorflow.keras.layers import Conv2D, MaxPooling2D from keras.layers import Conv2D, MaxPooling2D, Flatten, Dense, Dropout, InputLayer from keras.models import Sequential from keras import optimizers from keras.models import Sequential from keras.layers import Dense,Conv2D import tensorflow as tf from keras.applications import vgg16 from keras.models import Model import keras from keras.applications.imagenet_utils import preprocess_input from keras.preprocessing import image import os import cv2 import matplotlib.pyplot as plt import numpy as np import random It can take a lot of time (hours to days) to create neural network models and to train them using the traditional methods. But if one has pre-constructed network structure and pre-trained weights then it may take just a few seconds to do the same. This way, learning outcomes are transferred between different parties.Transfer learning generally refers to a process where a model which is trained on one problem is used in some way on another problem which is relatable. Furthermore, you don’t need to have a large scale training data set once learning outcomes transferred. Inception V3 is a type of CNN (Convolutional Neural Network) which consists of a lot of convolution and max pooling layers. It also contains fully connected neural networks. We don'y need to know its structure by heart to work with it, all that is handled by Keras. We would import Inception V3 and then we will construct a model using it as follows: from keras.applications.inception_v3 import InceptionV3 from keras.applications.inception_v3 import preprocess_input from keras.applications.inception_v3 import decode_predictions from keras.preprocessing import image import numpy as np import matplotlib.pyplot as plt model = InceptionV3(weights='imagenet', include_top=True) print("model structure: ", model.summary()) Now, we have pre-constructed network structure and pre-trained model for imagenet winner model. We can ask anything to Inception V3. Now, we will define a function named classification_v3 which will collect the training data and tell the 3 most probable candidates for each image for categories: Apple__Apple_scab, Apple__Cedar_apple_rust and Apple__Frogeye_Spot. Then, display image and its predictions together. datadir =loc # specify sub folder names in the list below catagories = ['Apple___Apple_scab','Apple___Cedar_apple_rust','Apple_Frogeye_Spot'] img_size = 299 training_data = [] def classification_v3(): for category in catagories: path = os.path.join(datadir,category) classnum = catagories.index(category) for img in os.listdir(path): img_arr = cv2.imread(os.path.join(path,img)) new_arr = cv2.resize(img_arr,(img_size,img_size)) x = np.expand_dims(new_arr, axis = 0) x = preprocess_input(x) features = model.predict(x) print(decode_predictions(features, top = 3)) plt.imshow(image.load_img(os.path.join(path,img))) plt.show() training_data.append([features,classnum]) classification_v3() print(len(training_data)) random.shuffle(training_data) Now that we have constructed a model and collected the training data along with its feature and labels, we will train the model by reshaping and scaling our training data to be fed to the model and defining a function get_features to return the features of the preprocessed training data when called. The main concept is stacking of convolutional layers to create deep neural networks.We used VGG16 (Visual Group Geaometry 16) model to create a neural network layer. import tensorflow as tf x=[] y=[] for feature , label in training_data: x.append(feature) y.append(label) X = np.array(x).reshape(-1,img_size,img_size,3)#1 is for grayscale for bgr/rgb 3 X.shape train_imgs_scaled = X.astype('float32') train_imgs_scaled /= 255 batch_size = 30 num_classes = 5 epochs = 30 input_shape = (150, 150, 3) vgg = tf.keras.applications.InceptionV3( include_top=True, weights='imagenet', input_tensor=None, input_shape=input_shape, pooling=None, classes=1000, classifier_activation='softmax' ) ''' vgg = vgg16.VGG16(include_top=False, weights='imagenet', input_shape=input_shape) ''' output = vgg.layers[-1].output output = keras.layers.Flatten()(output) vgg_model = Model(vgg.input, output) vgg_model.trainable = False for layer in vgg_model.layers: layer.trainable = False def get_features(model, input_imgs): features = model.predict(input_imgs, verbose=0) return features train_features_vgg = get_features(vgg_model, train_imgs_scaled) input_shape = vgg_model.output_shape[1] model = Sequential() model.add(InputLayer(input_shape=(input_shape,))) model.add(Dense(512, activation='relu', input_dim=input_shape)) model.add(Dropout(0.3)) model.add(Dense(512, activation='relu')) model.add(Dropout(0.3)) model.add(Dense(3, activation='softmax')) model.compile(loss='sparse_categorical_crossentropy', optimizer=optimizers.RMSprop(lr=1e-4), metrics=['accuracy']) history = model.fit(x=train_features_vgg, y=y, validation_split=0.3, batch_size=batch_size, epochs=1, verbose=1) The function Sequential( ) is used to group a linear stack of layers into a tf.keras.Model. We defined an instance of Sequential named 'model' and using it we added 3 hidden layers to the neural network. The first two layers have 'relu' as their activation function and the last one has 'softmax' as its activation function. We then combined all the layers using model.compile and trained the model on our training data. We will now check the accuracy and loss of the model and will plot the same. f, (ax1, ax2) = plt.subplots(1, 2, figsize=(12, 4)) t = f.suptitle('Performance', fontsize=12) f.subplots_adjust(top=0.85, wspace=0.3) epoch_list = list(range(1,31)) ax1.plot(epoch_list, history.history['accuracy'], label='Train Accuracy') ax1.plot(epoch_list, history.history['val_accuracy'], label='Validation Accuracy') ax1.set_xticks(np.arange(0, 31, 5)) ax1.set_ylabel('Accuracy Value') ax1.set_xlabel('Epoch') ax1.set_title('Accuracy') l1 = ax1.legend(loc="best") ax2.plot(epoch_list, history.history['loss'], label='Train Loss') ax2.plot(epoch_list, history.history['val_loss'], label='Validation Loss') ax2.set_xticks(np.arange(0, 31, 5)) ax2.set_ylabel('Loss Value') ax2.set_xlabel('Epoch') ax2.set_title('Loss') l2 = ax2.legend(loc="best") We can see that our model is almost accurate on training data. GitHub link: https://github.com/CodersArts2017/Jupyter-Notebooks/blob/master/plant_village_data_prediction_inception.ipynb

  • Research Paper Implementation : Recent Advances in Convolutional Neural Networks

    ABSTRACT Abstract In the last few years, deep learning has led to very good performance on a variety of problems, such as visual recognition, speech recognition and natural language processing. Among different types of deep neural networks, convolutional neural networks have been most extensively studied. Leveraging on the rapid growth in the amount of the annotated data and the great improvements in the strengths of graphics processor units, the research on convolutional neural networks has been emerged swiftly and achieved stateof-the-art results on various tasks. In this paper, we provide a broad survey of the recent advances in convolutional neural networks. We detailize the improvements of CNN on different aspects, including layer design, activation function, loss function, regularization, optimization and fast computation. Besides, we also introduce various applications of convolutional neural networks in computer vision, speech and natural language processing. Keywords: Convolutional Neural Network, Deep learning. To download full research paper click on the link below. If you need implementation of this research paper or any of its variants, feel free contact us on contact@codersarts.com.

  • Research Paper Implementation : Research Paper Recommender System Evaluation Using Coverage

    ABSTRACT Recommendation systems(RS)support users and developers of various computer and software systems to overcome information overload, perform information discovery tasks and approximate computation, among others. Recommender systems research is frequently based on comparisons of predictive accuracy: the better the evaluation scores, the better the recommender. However, it is difficult to compare results from different recommender systems due to the many options in design and implementation of an evaluation strategy. Additionally, algorithmic implementations can separate from the standard formulation due to manual tuning and modifications that work better in some situations. It have been compared common recommendation algorithms as implemented in three popular recommendation frameworks. We evaluate the quality of recommender systems, most approaches only focus on the predictive accuracy of these systems. Recent works suggest that beyond accuracy there is a variety of other metrics that should be considered when evaluating a RS. This paper reviews a range of evaluation metrics and measures as well as some approaches used for evaluating recommendation systems. Analysis shows that large differences in recommendation accuracy across frameworks and strategies. we are developing the recommender system for research papers using coverage. Key Words Recommender System, Research Paper Recommender System, Evaluation, Metrics, Coverage. To download full research paper click on the link below. If you need implementation of this research paper or any of its variants, feel free contact us on contact@codersarts.com.

  • Traffic Management System Using Java

    Abstract The goal of this assignment is to implement a set of classes and interfaces1 to be used to create a simulation of a traffic management system. You will implement precisely the public and protected items described in the supplied documentation (no extra public/protected members or classes). Private members may be added at your own discretion. Language requirements: Java version 13, JUnit 4 Introduction In this assignment you will finish building a simple simulation of a traffic management system (TMS). A traffic management system monitors traffic flow in a region and adjusts traffic signals to optimise traffic flow. A TMS uses different types of sensors and signals to monitor and manage traffic flow. In the first assignment you implemented the core model for the TMS. In the second assignment you will implement some of the more advanced logic to provide a very simple simulation for the TMS. In addition to the pressure pads and speed cameras from assignment one, you willl add a vehicle count sensor. It counts vehicles passing a location and reports the traffic flow as the number of vehicles in a time period. You need to integrate this new type of sensor into the system. This is an example of a common situation when building a large system. New features need to be added to the system. A well designed system that uses interfaces to define an API means it should be simple to add the new feature. In assignment one, you implemented traffic lights and electronic speed signs and attached them to a route. In assignment two you will provide logic to coordinate traffic lights at intersections. The TMS monitors sensors along routes and manages signals on routes, and at intersections, to optimise traffic flow. In assignment one, the network of routes was implicitly defined by your test code and SimpleDisplay. In assignment two you will implement the logic for the TMS to maintain a network of routes. This includes the ability to load a network from a data file and save a modified network to a file. Monitoring and managing congestion requires sophisticated logic in a real TMS. In assignment one congestion was simply reported by each sensor. In assignment two you will implement logic for congestion calculators. These take the congestion data from a set of sensors and determine overall congestion for the route(s) covered by the sensors. The approach taken is to define a CongestionCalculator interface that provides an API. Different classes can implement this inter- face to provide different options for the logic of determining congestion. This is another example of a common approach to designing flexibility into the system’s structure. When implementing the assignment you need to remember that it is implementing a simulation of the TMS and not the real TMS. Interfaces are provided for the sensors to allow easy replacement of sensor implementations in the program. You will not be collecting data from real sensors but will be implementing classes that demonstrate the behaviour of sensors. They store a set of data values that are used to simulate the sensors returning different values over time. Signals are simple simulations of real signals, in that they only store the current state of the signal and allow the route to update the signal. To manage simulation of time, there is a TimedItem interface and a TimedItemManager class, which you implemented in assignment one. Sensors implement the TimedItem interface, as they are items which need to react to timed events. TimedItemManager stores all the TimedItem ob- jects in the application. The simulation’s GUI tracks time passing in MainView.run() and it invokes MainViewModel.tick() once per second. The tick method calls the TimedItemManager’s oneSecond method, which sends the oneSecond message to all TimedItems. This approach of tracking the passage of time and invoking an action on all relevant objects once per second was the reason that TimedItemManager is implemented as a singleton2 . A simple GUI has been provided to you as part of the provided code. It is in the tms.display package. It will not work until you have implemented the other parts of the assignment that it uses. The GUI has been implemented using JavaFX and consists of three classes and an enum. MainView creates the main window for the TMS GUI. StructureView displays the structure of the traffic network. MainViewModel represents the TMS model that is to be displayed. The TMS application is initialised and started by the Launcher class in the tms package. It loads the traffic network data and creates the GUI. Most of the GUI code has been provided to you. In MainViewModel you need to implement some of the logic that is executed by events in the simulation and to handle keyboard input for the main application’s window. The functionality you need to implement in MainViewModel is to: Save the state of the network to a file in response to the user selecting the save command. This is to be implemented in MainViewModel.save(). Allow the simulation’s execution to be paused and unpaused. This is to be implemented in MainViewModel.togglePaused(). Process time passing in the simulation. This is to be implemented in MainViewModel.tick(). Keyboard input is handled by the accept method in the MainViewModel class. It needs to process input from the user in the main window to perform actions in the simulation. Pressing the ‘P’ key will toggle whether the simulation is paused or not. The ‘Q’ key will quit the simulation. The ‘S’ key will save the current network to a file called “DefaultSave.txt”. A shell for this method has been provided because it is already hooked into the GUI. Persistent Data You need to implement loading a network from a data file. The JavaDoc for the loadNetwork method in the NetworkInitialiser class describes the format of a network data file. Saving a network is done by the save method in the MainViewModel class. A network data file is structured as follows: The first line is the number of intersections (ni) in the file. The second line is the number of routes in the file. The third line is the duration of a yellow light. The following ni lines are the intersection details. The first part of an intersection line is its id. This is optionally followed by a ‘:’, a duration, another ‘:’, and a sequence of intersection ids which are separated by commas. The final set of lines are the route details, including any sensors on the routes. – Each route is on a separate line. The sensors for a route are on the lines immediately after the line for the route. – A route is described by the id of the from intersection, followed by a ‘:’, then the id of the to intersection, followed by a ‘:’, then the default speed for the route, followed by a ‘:’, then the number of sensors on the route, then optionally a ‘:’ and the speed of the electronic speed sign on the route if it has one. – If the route has any sensors, each sensor follows on separate lines. – The first part of a sensor line is its type ‘PP’, ‘SC’ or ‘VC’. This is followed by a ‘:’, then its threshold value, a ‘:’, and then a comma separated list of the data values used to simulate the data returned by the sensor. Any line that starts with a semi-colon ‘;’ is a comment and is to be ignored when reading the data from the file. Attempting to read an invalid network data file should throw an InvalidNetworkException. An example data file, called demo.txt, is provided in your repository in the networks directory. It corresponds to the diagram below. Supplied Material This task sheet. An example network data file. Code specification document (Javadoc) A Subversion repositiory for submitting your assignment called ass2. A simple graphical user interface for the simulation, which is in the display package. A sample solution for the first assignment. You are to use this as the base for your implementation of the second assignment. As the first step in the assignment you should create a new project by checking out the ass2 repository from Subversion. Javadoc Code specifications are an important tool for developing code in collaboration with other people. Although assignments in this course are individual, they still aim to prepare you for writing code to a strict specification by providing a specification document (in Java, this is called Javadoc). You will need to implement the specification precisely as it is described in the specification document. The Javadoc can be viewed in either of the two following ways: 1. Open https://csse2002.uqcloud.net/assignment/2/ in your web browser. Note that this will only be the most recent version of the Javadoc. 2. Navigate to the relevant assignments folder under Assessment on Blackboard and you will be able to download the Javadoc .zip file containing html documentation. Unzip the bundle somewhere, and open docs/index.html with your web browser. Tags in the Javadoc indicate what code has been implemented in assignment one and what code you need to implement in assignment two. Some code from assignment one will need to be modified. There are tags indicating places where you can expect to modify the assignment one code but these are not guaranteed to be all of the places where you may end up modifying code from assignment one. Tasks 1. Implement the classes and methods described in the Javadoc as being requried for assignment two. 2. Implement the indicated features of the user interface. 3. Write JUnit 4 tests for all the methods in the following classes: AveragingCongestionCalculator (in a class called AveragingCongestionCalculatorTest) IntersectionLights (in a class called IntersectionLightsTest) NetworkInitialiser (in a class called NetworkInitialiserTest) Submission Submission is via your Subversion repository. You must ensure that you have committed your code to your repository before the submission deadline. Code that is submitted after the deadline will not be marked. Failure to submit your code through your repository will result in it not being marked. Details for how to submit your assignment are available in the Version Control Guide. Your repository url is: https://source.eait.uq.edu.au/svn/csse2002-s???????/trunk/ass2 — CSSE2002 students or https://source.eait.uq.edu.au/svn/csse7023-s???????/trunk/ass2 — CSSE7023 students Your submission should have the following internal structure: src/ folders (packages) and .java files for classes described in the Javadoc test/ folders (packages) and .java files for the JUnit test classes A complete submission would look like: src/tms/congestion/AveragingCongestionCalculator.java src/tms/congestion/CongestionCalculator.java src/tms/display/ButtonOptions.java src/tms/display/MainView.java src/tms/display/MainViewModel.java src/tms/display/StructureView.java src/tms/intersection/Intersection.java src/tms/intersection/IntersectionLights.java src/tms/network/Network.java src/tms/network/NetworkInitialiser.java src/tms/route/Route.java src/tms/route/SpeedSign.java src/tms/route/TrafficLight.java src/tms/route/TrafficSignal.java src/tms/sensors/DemoPressurePad.java src/tms/sensors/DemoSensor.java src/tms/sensors/DemoSpeedCamera.java src/tms/sensors/DemoVehicleCount.java src/tms/sensors/PressurePad.java src/tms/sensors/Sensor.java src/tms/sensors/SpeedCamera.java src/tms/sensors/VehicleCount.java src/tms/util/DuplicateSensorException.java src/tms/util/IntersectionNotFoundException.java src/tms/util/InvalidNetworkException.java src/tms/util/InvalidOrderException.java src/tms/util/RouteNotFoundException.java src/tms/util/TimedItem.java src/tms/util/TimedItemManager.java src/tms/Launcher.java test/tms/congestion/AveragingCongestionCalculatorTest.java test/tms/intersection/IntersectionLightsTest.java test/tms/network/NetworkInitialiserTest.java test/tms/JdkTest.java Ensure that your assignments correctly declare the package they are within. For example, CongestionCalculator.java should declare package tms.congestion. Do not submit any other files (e.g. no .class files). Note that AveragingCongestionCalculatorTest, IntersectionLightsTest and NetworkInitialiserTest will be compiled without the rest of your files. If you are looking solution of this project assignment then you can contact us at below contact detail, we will also provide other java related technology help: JavaFx, Spring, J2EE, etc. contact@codersarts.com

  • Research Paper Implementation : New Thinking on, and with, Data Visualization.

    ABSTRACT As the complexity and volume of datasets have increased along with the capabilities of modular, open-source, easy-to-implement, visualization tools, scientists’ need for, and appreciation of, data visualization has risen too. Until recently, scientists thought of the “explanatory” graphics created at a research project’s conclusion as “pretty pictures” needed only for journal publication or public outreach. The plots and displays produced during a research project--often intended only for experts--were thought of as a separate category, what we here call “exploratory” visualisation. In this view, discovery comes from exploratory visualisation, and explanatory visualisation is just for communication. Our aim in this paper is to spark conversation amongst scientists, computer scientists, outreach professionals, educators, and graphics and perception experts about how to foster flexible data visualisation practices that can facilitate discovery and communication at the same time. We present an example of a new finding made using the glue visualisation environment to demonstrate how the border between explanatory and exploratory visualisation is easily traversed. The linked-view principles as well as the actual code in glue are easily adapted to astronomy, medicine, and geographical information science--all fields where combining, visualising, and analysing several high-dimensional datasets yields insight. Whether or not scientists can use such a flexible “undisciplined” environment to its fullest potential without special training remains to be seen. We conclude with suggestions for improving the training of scientists in visualization practices, and of computer scientists in the iterative, non-workflow-like, ways in which modern science is carried out. To download full research paper click on the link below. If you need implementation of this research paper or any of its variants, feel free contact us on contact@codersarts.com.

  • Linear Regression: Boston Housing data set

    We will work with Boston housing data set which consists information about houses in Boston. It is provided in scikit-learn library. There are 506 samples and 13 feature variables in this dataset. The objective is to predict the value of prices of the house based on number of rooms. For this we will implement linear regression. First we will load the Boston data set from sklearn.datasets and then we will convert it into a dataframe using pandas so that we can easily work with it. We use NumPy to work with arrays.We will use matplotlib and seaborn to visualise the data. import numpy as np import pandas as pd import seaborn as sns import matplotlib.pyplot as plt from sklearn.datasets import load_boston %matplotlib inline from sklearn import datasets from sklearn.linear_model import LinearRegression from sklearn.model_selection import train_test_split, cross_val_score from sklearn.metrics import mean_squared_error boston= load_boston() boston.keys() Output: dict_keys(['data', 'target', 'feature_names', 'DESCR', 'filename']) data: contains the information for various houses target: prices of the house feature_names: names of the features DESCR: describes the data set bos = pd.DataFrame(boston.data, columns = boston.feature_names) bos['PRICE'] = boston.target bos.head() Now, we will explore the data to understand it better. We will look at the descriptive statistics of the data using the describe( ) function. bos.describe() We will plot a histogram of PRICE feature. sns.set(rc={'figure.figsize':(11.7,8.27)}) plt.hist(bos['PRICE'],color = 'red', bins=30) plt.xlabel("House prices in $1000") plt.show() We observe that the data is distributed normally and that there are only a few outliers. Next, we create a correlation matrix that measures the linear relationships between the variables. It can be done by using the function corr( ). We will use the heatmap function from the seaborn library to plot the correlation matrix. bos_1 = pd.DataFrame(boston.data, columns = boston.feature_names) bos_1['PRICE']=boston.target correlation_matrix = bos_1.corr().round(2) sns.heatmap(data=correlation_matrix, annot=True) The correlation coefficient ranges from -1 to 1. If the value is close to 1, it means that there is a strong positive correlation between the two variables. If it is close to -1, the variables have a strong negative correlation. We prefer to use features with high correlation (whether positive or negative) with our target feature PRICE, to fit to the model. The feature RM has a strong positive correlation with PRICE (0.7) where as LSTAT has a high negative correlation (-0.74). We will draw a scatterplot of RM and LSTAT against PRICE to better visualise the correlation. plt.figure(figsize=(20, 5)) features = ['LSTAT', 'RM'] target = bos['PRICE'] for i, col in enumerate(features): plt.subplot(1, len(features) , i+1) x = bos[col] y = target plt.scatter(x, y,color='green', marker='o') plt.title("Variation in House prices") plt.xlabel(col) plt.ylabel('"House prices in $1000"') Also, an important point in selecting features for a linear regression model is to check for multi-co-linearity. The features RAD, TAX have a correlation of 0.91. These feature pairs are strongly correlated to each other. We should not select both these features together for training the model. Same goes for the features DIS and AGE which have a correlation of -0.75. Since we want to predict prices based on number of rooms only. We will only use RM feature to train on the model and PRICE feature will be our target. X_rooms = bos.RM y_price = bos.PRICE X_rooms = np.array(X_rooms).reshape(-1,1) y_price = np.array(y_price).reshape(-1,1) X_train_1, X_test_1, Y_train_1, Y_test_1 = train_test_split(X_rooms, y_price, test_size = 0.2, random_state=5) We have split the data set into training and test set. So, that we can make sure that our model performs well on unseen data. We fit our training data to LinearRegresion model and train it. We also calculate the RMSE (root mean square error) and R2 score to see how well our model performs. reg_1 = LinearRegression() reg_1.fit(X_train_1, Y_train_1) y_train_predict_1 = reg_1.predict(X_train_1) rmse = (np.sqrt(mean_squared_error(Y_train_1, y_train_predict_1))) r2 = round(reg_1.score(X_train_1, Y_train_1),2) print('RMSE is {}'.format(rmse)) print('R2 score is {}'.format(r2)) print("\n") We get : RMSE is 6.972277149440585 R2 score is 0.43 Our model has been trained. Now, we will use it on test data. reg_1 = LinearRegression() reg_1.fit(X_train_1, Y_train_1) y_train_predict_1 = reg_1.predict(X_train_1) rmse = (np.sqrt(mean_squared_error(Y_train_1, y_train_predict_1))) r2 = round(reg_1.score(X_train_1, Y_train_1),2) print('RMSE is {}'.format(rmse)) print('R2 score is {}'.format(r2)) print("\n") We get: Root Mean Squared Error: 4.895963186952216 R^2: 0.69 We can see that our model worked better on the test set. We will now plot or predictions: prediction_space = np.linspace(min(X_rooms), max(X_rooms)).reshape(-1,1) plt.scatter(X_rooms,y_price) plt.plot(prediction_space, reg_1.predict(prediction_space), color = 'black', linewidth = 3) plt.ylabel('value of house/1000($)') plt.xlabel('number of rooms') plt.show() GitHub Link: https://github.com/CodersArts2017/Jupyter-Notebooks/blob/master/bosten_data_analysis.ipynb

  • Unsupervised Machine Learning: Classification of Iris data set

    The Iris data set is the 'Hello world' in the field of data science. This data sets consists of 3 different types of irises’ (Setosa, Versicolour, and Virginica) petal and sepal length, stored in a 150x4 numpy.ndarray. The rows being the samples and the columns being: Sepal Length, Sepal Width, Petal Length and Petal Width. The data set is often used in data mining, classification and clustering examples and to test algorithms. First we will load the Iris data set from sklearn.datasets and then we will convert it into a dataframe using pandas so that we can easily work with it. We will use matplotlib and seaborn to visualise the data. from sklearn.datasets import load_iris import matplotlib.pyplot as plt import pandas as pd import numpy as np import seaborn as sns dataset=load_iris() data=pd.DataFrame(dataset['data'],columns=['Petal length','Petal Width','Sepal Length','Sepal Width']) data['Species']=dataset['target'] data['Species']=data['Species'].apply(lambda x: dataset['target_names'][x]) data.head() Now, we will explore the data to understand it better and to make it suitable to be fed to the machine learning algorithm. We will check for missing values in the data: data.isnull().sum() We see that there are no missing value in this data set. We will check the information about our DataFrame including the index dtype and columns, non-null values and memory usage, by callling the info( ) function. data.info() We can see that there are 150 total rows and there is no missing value. The type of each column is also specified. Now, we will look at the descriptive statistics of the data using the describe( ) function. data.describe() We will now make a pairplot using seaborn to visualize the relationship between the columns of the data frame for different species. sns.pairplot(data,hue='Species') We can see the range of petal length, petal width, sepal length and sepal width for the 3 species easily from the graph. Thus, we can determine to which species a new data point might belong to. We can also visualise our dataframe using a heatmap,a violin plot and a boxplot; as follows: Heatmap: plt.figure(figsize=(10,11)) sns.heatmap(data.corr(),annot=True) plt.plot() Violin plot: plt.figure(figsize=(12,10)) plt.subplot(2,2,1) sns.violinplot(x='Species',y='Sepal Length',data=data) plt.subplot(2,2,2) sns.violinplot(x='Species',y='Sepal Width',data=data) plt.subplot(2,2,3) sns.violinplot(x='Species',y='Petal length',data=data) plt.subplot(2,2,4) sns.violinplot(x='Species',y='Petal Width',data=data) Boxplot: plt.figure(figsize=(12,10)) plt.subplot(2,2,1) sns.boxplot(x='Species',y='Sepal Length',data=data) plt.subplot(2,2,2) sns.boxplot(x='Species',y='Sepal Width',data=data) plt.subplot(2,2,3) sns.boxplot(x='Species',y='Petal length',data=data) plt.subplot(2,2,4) sns.boxplot(x='Species',y='Petal Width',data=data) Now, we need to replace the values of species column with some numerical value so that it will be easier for the machine to understand. This process is called encoding. We will replace 'setosa' with '0', 'versicolor' with '1' and 'virginica' with '2'. from sklearn import preprocessing le = preprocessing.LabelEncoder() le.fit(data['Species']) y =le.transform(data['Species']) y We can see that the species column have been encoded using LabelEncoder from preprocessing class of sklearn library. Now, our data is ready to be trained on different classification models. Here we will be training our data on DecisionTreeClassifier, SupportVectorClassifier, RandomForestClassifier and KNeighboursClassifiers, then we will determine which algorithm worked better. DecisionTreeClassifier from sklearn.tree import DecisionTreeClassifier from sklearn.model_selection import cross_val_score DT = DecisionTreeClassifier(random_state=0) score1=cross_val_score(DT, data[['Petal length','Petal Width','Sepal Length']], y, cv=10) print(score1.mean()) Output: 0.9466666666666667 SupportVectorClassifier from sklearn.svm import SVC svm_clf =SVC(gamma='auto') score2=cross_val_score(svm_clf, data[['Petal length','Petal Width','Sepal Length']], y, cv=10) print(score2.mean()) Output: 0.9533333333333334 RandomForestclassifier from sklearn.ensemble import RandomForestClassifier RFC = RandomForestClassifier(max_depth=2, random_state=0) score3=cross_val_score(RFC, data[['Petal length','Petal Width','Sepal Length']], y, cv=10) print(score3.mean()) Output: 0.9133333333333333 KNeighboursClassifiers from sklearn.neighbors import KNeighborsClassifier KNN = KNeighborsClassifier(n_neighbors=3) score4=cross_val_score(RFC, data[['Petal length','Petal Width','Sepal Length']], y, cv=10) print(score4.mean()) Output: 0.9133333333333333 The output of the above code snippets shows the accuracy of the model. The higher the accuracy the better the model at classifying correctly. We can see that SupportVectorClassifier was the best at classifying correctly followed by DecisionTreeClassifier and then by RandomForestClassifier and KNeighboursClassifiers both of which performed equally. We can't say that this is always true. Different algorithms work better in different situations. So we should always train our data on a number of algorithms and we should then select the best. GitHub link: https://github.com/CodersArts2017/Jupyter-Notebooks/raw/master/IRIS_CONTENT.ipynb

  • Research Paper Implementation : Machine Translation for Academic Purposes.

    ABSTRACT Due to the globalization trend and knowledge boost in the second millennium, multi-lingual translation has become a noteworthy issue. For the purposes of learning knowledge in academic fields, Machine Translation (MT) should be noticed not only academically but also practically. MT should be informed to the translating learners because it is a valuable approach to apply by professional translators for diverse professional fields. For learning translating skills and finding a way to learn and teach through bi-lingual/multilingual translating functions in software, machine translation is an ideal approach that translation trainers, translation learners, and professional translators should be familiar with. In fact, theories for machine translation and computer assistance had been highly valued by many scholars. (e.g., Hutchines, 2003; Thriveni, 2002) Based on MIT’s Open Courseware into Chinese that Lee, Lin and Bonk (2007) have introduced, this paper demonstrates how MT can be efficiently applied as a superior way of teaching and learning. This article predicts the translated courses utilizing MT for residents of global village should emerge and be provided soon in industrialized nations and it exhibits an overview about what the current developmental status of MT is, why the MT should be fully applied for academic purpose, such as translating a textbook or teaching and learning a course, and what types of software can be successfully applied. It implies MT should be promoted in Taiwan because its functions of clearly translating the key-words and leading the basic learners to a certain professional field can be proved in MIT. Keywords Machine Translation, Computational Linguistics, Bi-lingual/Multilingual Translating, Open Courseware. To download full research paper click on the link below. If you need implementation of this research paper or any of its variants, feel free contact us on contact@codersarts.com.

  • Research Paper Implementation : Autoencoders, Unsupervised Learning, and Deep Architectures.

    ABSTRACT Autoencoders play a fundamental role in unsupervised learning and in deep architectures for transfer learning and other tasks. In spite of their fundamental role, only linear autoencoders over the real numbers have been solved analytically. Here we present a general mathematical framework for the study of both linear and non-linear autoencoders. The framework allows one to derive an analytical treatment for the most non-linear autoencoder, the Boolean autoencoder. Learning in the Boolean autoencoder is equivalent to a clustering problem that can be solved in polynomial time when the number of clusters is small and becomes NP complete when the number of clusters is large. The framework sheds light on the different kinds of autoencoders, their learning complexity, their horizontal and vertical composability in deep architectures, their critical points, and their fundamental connections to clustering, Hebbian learning, and information theory. KEYWORDS autoencoders, unsupervised learning, compression, clustering, principal component analysis, boolean, complexity, deep architectures, hebbian learning, information theory. To download full research paper click on the link below. If you need implementation of this research paper or any of its variants, feel free contact us on contact@codersarts.com.

  • Research Paper Implementation : Sequence to Sequence Learning with Neural Networks.

    ABSTRACT Deep Neural Networks (DNNs) are powerful models that have achieved excellent performance on difficult learning tasks. Although DNNs work well whenever large labelled training sets are available, they cannot be used to map sequences to sequences. In this paper, we present a general end-to-end approach to sequence learning that makes minimal assumptions on the sequence structure. Our method uses a multilayered Long Short-Term Memory (LSTM) to map the input sequence to a vector of a fixed dimensionality, and then another deep LSTM to decode the target sequence from the vector. Our main result is that on an English to French translation task from the WMT-14 dataset, the translations produced by the LSTM achieve a BLEU score of 34.8 on the entire test set, where the LSTM’s BLEU score was penalized on out-of-vocabulary words. Additionally, the LSTM did not have difficulty on long sentences. For comparison, a phrase-based SMT system achieves a BLEU score of 33.3 on the same dataset. When we used the LSTM to rerank the 1000 hypotheses produced by the aforementioned SMT system, its BLEU score increases to 36.5, which is close to the previous state of the art. The LSTM also learned sensible phrase and sentence representations that are sensitive to word order and are relatively invariant to the active and the passive voice. Finally, we found that reversing the order of the words in all source sentences (but not target sentences) improved the LSTM’s performance markedly, because doing so introduced many short term dependencies between the source and the target sentence which made the optimisation problem easier. To download full research paper click on the link below. If you need implementation of this research paper or any of its variants, feel free contact us on contact@codersarts.com.

  • Predicting Cab Supply and Demand(Cab Booking System)

    About the project: Cab booking system is the process where renting a cab is automated through an app throughout a city. Using this app, people can book a cab from one location to another location. Being a cab booking app company, exploiting the understanding of cab supply and demand could increase the efficiency of their service and enhance the user experience by minimizing waiting time. Objective of this project is to combine historical usage patterns along with open data sources like weather data to forecast cab booking demand in a city. You will be provided with an hourly renting data span of two years. Data is randomly divided into train and test sets. You must predict the total count of cabs booked in each hour covered by the test set, using the information available prior to the booking period. You need to append the train_label dataset to train.csv as the ‘Total_booking’ column. Please find the descriptions of the columns present in the dataset below. datetime - hourly date + timestamp season - spring, summer, autumn, winter holiday - whether the day is considered a holiday workingday - whether the day is neither a weekend nor holiday weather - Clear , Cloudy, Light Rain, Heavy temp - temperature in Celsius atemp - "feels like" temperature in Celsius humidity - relative humidity windspeed - wind speed Total_booking - number of total booking DATASET The recommended datasets will be shared. You can download them from the LMS TASKS Following are the tasks, which need to be developed while executing the project: Task 1: 1. Visualize data using different visualizations to generate interesting insights. 2. Outlier Analysis 3. Missing value analysis 4. Visualizing Total_booking Vs other features to generate insights 5. Correlation Analysis Task 2: 1. Feature Engineering 2. Grid search 3. Regression Analysis 4. Ensemble Model Solution: Task 1: import pandas as pd # Here, I have append the rows of train dataset and test dataset df11=pd.read_csv('C:/Project_1_dataset/Dataset/train.csv') df111=pd.read_csv('C:/Project_1_dataset/Dataset/test.csv') df1=df11.append(df111,ignore_index=True) # Here, I have append the rows of train_label dataset and test_label dataset df22=pd.read_csv('C:/Project_1_dataset/Dataset/train_label.csv', header=None, names=['Total_Booking']) df222=pd.read_csv('C:/Project_1_dataset/Dataset/test_label.csv', header=None, names=['Total_Booking']) df2=df22.append(df222,ignore_index=True) # Here, I have Concatenate the columns of df1 and df2 dataset to get complete dataset. df = pd.concat([df1, df2], axis=1) df1=df you can change the path and add your own path where you can add these train and test datasets. # here, I have drop the duplicates rows from the dataset df. df=df.drop_duplicates() df Identifying Missing Values # Here, I have checked the Missing value in the dataset df.isnull().sum() Output: datetime 0 season 0 holiday 0 workingday 0 weather 0 temp 0 atemp 0 humidity 0 windspeed 0 Total_Booking 0 dtype: int64 # Here, I have checked the datatype of the given Columns. df.dtypes Output: datetime object season object holiday int64 workingday int64 weather object temp float64 atemp float64 humidity int64 windspeed float64 Total_Booking int64 dtype: object Outliers Analysis #Here, I have checked the outliers in the windspeed column through the boxplot graph. import seaborn as sns sns.boxplot(x=df['windspeed']) #Here, I have checked the outliers in the Humidity column through the boxplot graph. import seaborn as sns sns.boxplot(x=df['humidity']) As like above, you can get all outliers of each dataset columns: # Here, I have checked the outliers in the windspeed vs Total_Booking column through the scatter graph. import matplotlib.pyplot as plt import matplotlib fig, ax = plt.subplots(figsize=(16,8)) ax.scatter(df['windspeed'], df['Total_Booking']) ax.set_xlabel('Wind Speed') ax.set_ylabel('Total Booking') plt.show() Output: # Here, I am finding the zscore values of the numerical columns of the dataset df. from scipy import stats import numpy as np z = np.abs(stats.zscore(df[['windspeed','temp','atemp','humidity','Total_Booking']])) print(z) Output: [[0.5142603 0.24503701 0.24839078 0.78535767 1.7248125 ] [0.75963759 1.08700912 1.14227927 0.88928536 1.03002161] [1.12729319 1.85989326 2.07630932 0.61766615 0.29024652] ... [0.8819159 0.17594904 0.10975464 0.14999154 0.17983232] [0.46560752 0.38644207 0.28853234 1.66874304 0.89752458] [0.5142603 1.29750214 1.32105696 0.21375537 0.1790138 ]] # Here, I have checked where thresold is greater than 3. threshold = 3 print(np.where(z > 3)) # Here, I have drop the rows where zscore is less than 3 to remove the outliers of the dataset df df = df[(z < 3).all(axis=1)] # After removing the outliers, The dataset df is : df Output: # Here, You have to see in the boxplot graph that maximum outliers are remove from the windspeed column. Only three left import seaborn as sns sns.boxplot(x=df['windspeed']) Output: As like above, you can remove all outliers from other columns. Visualize data using different visualizations to generate interesting insights. # Show value counts for a weather Column of dataset df_o: import matplotlib.pyplot as plt import seaborn as sbn sbn.countplot(x='weather',data=df) plt.xticks(rotation=90) plt.show() Output: # Show value counts for a season Column and weather Column of dataset df_o: import seaborn as sbn sbn.countplot(x='season',data=df,hue='weather') plt.show() Output: # Show value counts for a season Column and Holiday Column of dataset df_o where 0 value represent No Holiday and 1 value represent Holiday: import seaborn as sbn sbn.countplot(x='season',data=df,hue='holiday') plt.show() Output: # Show value counts for a season Column and WorkingDay Column of dataset df_o where 0 value represent No WorkingDay and 1 value represent WorkingDay: import seaborn as sbn sbn.countplot(x='season',data=df,hue='workingday') plt.show() Output: # Here, I have draw the Pie chart between HoliDay, WorkingDay And No Holiday No Workingday to check the status in percentile. Not_Holiday_Not_workingday=df[(df.holiday==0) & (df.workingday==0)].shape[0] print('No working and No Holiday = ', Not_Holiday_Not_workingday) Holiday=df[(df.holiday==1)].shape[0] print('Total HoliDay = ', Holiday) WorkingDay=df[(df.workingday==1)].shape[0] print('Total Working Day = ', WorkingDay) plt.pie(x=[Not_Holiday_Not_workingday,WorkingDay,Holiday],labels=['No Holiday & No workingday','WorkingDay','Holiday'],explode=(.1,.1,.1),colors=['g','r','b'],autopct='%.2f',wedgeprops={'edgecolor':'k'}) plt.show() Output: Fetch specified value from dataset column value #Here, I have fetch the Months from the datetime column df1['booking_month'] = pd.to_datetime(df1.datetime, format='%m/%d/%Y %H:%M').dt.month_name() #Here, I have fetch the Days from the datetime column df1['booking_day'] = pd.to_datetime(df1.datetime, format='%m/%d/%Y %H:%M').dt.day_name() #The time of departure is in 24 hours format(22:20), we would like to bin it to get insights. #Here, I have decided to group hours into 4 bins. [0–5], [6–11], [12–17] and [18–23] are the 4 bins. df1['timing'] = pd.to_datetime(df1.datetime, format='%m/%d/%Y %H:%M') a = df1.assign(dept_session=pd.cut(df1.timing.dt.hour,[0,6,12,18,24],labels=['Night','Morning','Afternoon','Evening'])) df1['booking_session'] = a['dept_session'] #Here, I have fetch the Year from the datetime column l2=[] for i in range(0,df1.shape[0]): l2.append(df1.datetime[i][df1.datetime[i].rindex('/')+1:df1.datetime[i].rindex('/')+5]) df1['year']=pd.DataFrame(l2,columns=['year']) df1 Output: # Show value counts for a Months Column of dataset df. import matplotlib.pyplot as plt import seaborn as sbn sbn.countplot(x='booking_month',data=df1) plt.xticks(rotation=90) plt.show() Output: # Show value counts for a Day Column of dataset df. import matplotlib.pyplot as plt import seaborn as sbn sbn.countplot(x='booking_day',data=df1) plt.xticks(rotation=90) plt.show() Output: # Show value counts for a Year Column and booking_session column of dataset df. import matplotlib.pyplot as plt import seaborn as sbn sbn.countplot(x='year',data=df1,hue='booking_session') plt.xticks(rotation=90) plt.show() Output: Visualizing Total_booking Vs other features to generate insights # Show the Line Plot Between booking_Month vs Total_Booking column import matplotlib.pyplot as plt import seaborn as sbn sbn.lineplot(x="booking_month", y="Total_Booking", data=df) plt.xticks(rotation=90) Output: # Show the Line Plot Between booking_day vs Total_Booking column. import matplotlib.pyplot as plt import seaborn as sbn sbn.lineplot(x="booking_day", y="Total_Booking", data=df) plt.xticks(rotation=90) Output: Correlation Analysis: df.corr('spearman') Task 2 : Feature Engineering import pandas as pd # Here, I have append the rows of train dataset and test dataset df11=pd.read_csv('C:/Project_1_dataset/Dataset/train.csv') df111=pd.read_csv('C:/Project_1_dataset/Dataset/test.csv') df1=df11.append(df111,ignore_index=True) # Here, I have append the rows of train_label dataset and test_label dataset df22=pd.read_csv('C:/Project_1_dataset/Dataset/train_label.csv', header=None, names=['Total_Booking']) df222=pd.read_csv('C:/Project_1_dataset/Dataset/test_label.csv', header=None, names=['Total_Booking']) df2=df22.append(df222,ignore_index=True) # Here, I have Concatenate the columns of df1 and df2 dataset to get complete dataset. df = pd.concat([df1, df2], axis=1) df Output: # Here, I have checked the datatype of the given Columns. df.dtypes Output: datetime object season object holiday int64 workingday int64 weather object temp float64 atemp float64 humidity int64 windspeed float64 Total_Booking int64 dtype: object Contact us to get a complete solution or need any other related machine learning project help, then you can contact us at below contact detail: contact@codersarts.com

bottom of page