## My Experience taking GRE General Test at Home

This year, I got a new experience to take the GRE General Test at Home (online GRE Test). I took this test because of a need that requires including GRE scores even though there is no minimum requirement. Therefore, I took the GRE test with super minimal preparation. So don’t expect this article to tell you about tips for dealing with the GRE. I’m just going to share my experience taking the GRE General Test at Home.

For those interested in studying abroad, you must have heard of the GRE test. In some campuses abroad, in addition to an English certificate, we are usually also required to include a GRE score with a certain minimum. But at some other campuses, the GRE is not mandatory. So, before taking this test, make sure you need to take this test. I’ve never even heard that the GRE test can be used for college admission requirements in Indonesia.

The GRE test is different from the IELTS or TOEFL test that is available almost everywhere. The GRE test is only available in certain cities. What I know is in Bandung, Jakarta, and Surabaya. But recently, there is an At-Home Test option, where we can test GRE at home online.

## GRE General Test

The test is consist of 3 sections: Verbal, Quantitative , & Analytical Writing.

Verbal test, in general, there are two types of questions here: reading comprehension and word choice. Regardless of the type, the biggest challenge on this test is the English vocabulary. During the test, we will meet with difficult (unbelievably) words that I never encounter .-. (“enervate”, “prodigal”, “laconic”, “calumny”, …) and we must understand its meaning and usage.

Quantitative test, (usually just called “Quant”) as the name implies, this is a basic math test. Although basic, this test is not just basic arithmetic like the TPA test here. The problem is more complicated and more tricky. We need to remember the basic geometric formulas, combinations, permutations again, and more importantly, just memorizing formulas doesn’t help.

Analytical Writing test, In this test, we will be asked to write two English essays that are correct grammatically and logically. In the first essay, we will be asked to respond to an issue, and in the second essay, we will be asked to make logical rebuttals from other people’s statements.

## Software for online teaching for Ubuntu users

Last semester all lectures were 100% online. Very challenging, especially for me, who uses a computer with the Ubuntu operating system. It isn’t very easy when recommended online teaching software only compatible with Windows/macOS. In this article, I will share some useful software for teaching online for Ubuntu users. While teaching online during this pandemic, I have been greatly helped by this software. Hopefully, it is useful for readers out there.

## Simple Screen Recorder

The first software I want to share is screen recording software. Because when teaching online, sometimes I have to make video tutorials for my classes. In my opinoin, Simple Screen Recorder is the best choice. The features I want to highlight:

• Simple. Super simple. I have tried several other screen recording software on Ubuntu, but none are as complete and straightforward as a simple screen recorder.
• Can record by a window, follow the mouse, or a specific area on the screen. Another alternative that I’ve ever done to make a recorded video is to use Zoom. But in the zoom, there is no option to capture a particular area. It’s quite useful when we want to record with a “cheat sheet” on the screen.
• Video quality settings are also very easy. I usually use “youtube” quality with a frame rate of 30. The resulting video will have reasonable quality with reasonable file size. A video of approximately 10 minutes will be around 25 MB in size.
• The feature I like the most is their short cut. Yups, I can set my short cut so that the record-stop-save process can quickly be done behind the scenes. As long as the application is running, even though it is in a minimized state, I just need to press my shortcut button, and then the software will start recording the screen. I press it again, and then the video will be saved. Super simple.

I experienced the drawback with Simple Screen Recorder when I wanted to record an audio source from a laptop (e.g., I want to displayed sound/video). The audio source cannot be changed in the middle of the recording. For example, suppose you want to record audio from a computer and a mic. In that case, you have to separate it into two different videos or use other software, for example, Zoom or Kazam (which, in my opinion, is not simple).

## Neural Net in 4 lines! using Scikit-Learn MLPClassifier

See the code below:

from sklearn.neural_network import MLPClassifier

mlp = MLPClassifier(hidden_layer_sizes=(10),solver='sgd',
learning_rate_init=0.01,max_iter=500)

mlp.fit(X_train, y_train)

print mlp.score(X_test,y_test)

That’s right, those 4 lines code can create a Neural Net with one hidden layer! 😐

Scikit-learn just released stable version 0.18. One of the new features is MLPClassifer and you can see in the code above, it’s powerful enough to create a simple neural net program.

That code just a snippet of my Iris Classifier Program that you can see on Github. Of course, in practice, you still need to create loader, pre-process, pre-training, or other modules. But, if you see other python libraries like Keras, Lasagne, or Theano, I think this is the easiest way to create a simple neural net. I said “simple” because when you need to create more complex model that need more complex algorithm or many addons, I think it’ll become difficult to use MLPClassifier. But, for some simple project, I think I’ll choose this scikit tool 🙂

Program Explanation

Line 1: you need to load MLPClassifier

Line 2: we create an object called ‘mlp’ which is a MLPClassifier. We set hidden_layer_size to (10) which means we add one hidden layer with 10 neurons. Then we set solver as ‘sgd’ because we will use Stochastic Gradient Descent as optimizer. Then we set learning_rate_init to 0.01, this is a learning rate value (be careful, don’t confuse with alpha parameter in MLPClassifer). Then the last, we set 500 as the maximum number of training iteration.

Line 3: Train the model

Line 4: Test the model

That’s it! and my first run I got more than 90% accuration in Iris Dataset 🙂 try it!

And actually, you can create “Deeper” neural net with add more layers easily, just change hidden_layer_sizes. For example, hidden_layer_sizes=(10,10,10) will create 3 hidden layer with 10 neuron each.

source image: Flickr

## Simple Tutorial Python, Boto3, and AWS S3

I’ve horrible experience to find “good” tutorial about how to use Boto3 in Amazon Web Service (AWS). Boto3, not like Boto2, has poor quality documentation. So I create this simple tutorial as reminder to myself and I hope it will help someone out there.

## Boto3

The AWS SDK for Python. It simply to said, if you have a python apps and you want it to access AWS features, you need this.

## Installation & Setup

Installation is very clear in python documentation and for configuration you can check in Boto3 documentation just using pip:

$pip install boto3 after install boto3 you can use awscli to make it easier setup credentials, install it using pip too: $ pip install awscli

set your configuration using command below. You can get your access key and secret key in IAM console:

\$ aws configure

## Create A Simple App

Let’s create a simple app using Boto3. We will create a simple app to access stored data in AWS S3. This app will write and read a json file stored in S3.

First, you need to create a bucket in your S3. You can create bucket by visiting your S3 service and click Create Bucket button.

or using some code below:

import boto3
import json

data = {"HelloWorld": []}
s3 = boto3.resource('s3')
s3.create_bucket(Bucket='my-bucket')

If you confuse what is bucket and how it works, this one have nice explanation.

### 2. Write JSON File

Next part is how to write a file in S3. The code below will create a json file (if it doesn’t exist, or overwrite it otherwise) named hello.json and put it in your bucket.

import boto3
import json

data = {"HelloWorld": []}
s3 = boto3.resource('s3')
obj = s3.Object('my-bucket','hello.json')
obj.put(Body=json.dumps(data))

If you want to put it on specific path, you can change the line

obj = s3.Object('my-bucket','hello.json')

to

obj = s3.Object('my-bucket','my-path/hello.json')

Run it, and if you check your bucket now you will find your file in there.

Last but not least, if you want to read your file, you can use get() function. The code below will read your hello.json file and show it on screen. File body/content will be read as string by default.

import boto3

data = {"HelloWorld": []}
s3 = boto3.resource('s3')
obj = s3.Object('my-bucket','hello.json')
print data

I think that’s all, a simple tutorial using boto3 to read-write file in Amazon Web Service S3. Hope it helps 🙂

## A* Algorithm in Python to solve 8 puzzle problem

My team got this as A* algorithm assignment in Artificial Intelligence class few years ago taught by Mrs. Afiahayati, Ph.D. We should create an implementation of A* algorithm (read: “A” Star) to solve 8 puzzle problem. This puzzle problem is the small version of 15 sliding puzzle game.

## A* Algorithm

In my opinion A* Algorithm (read more about it here) is looks like combination of Breadth First Search (BFS) and Depth First Search (DFS) algorithm (or maybe Dijkstra’s too(?)). It’s using Heuristic scoring to estimate the step from vertex to goal so make the system may running faster, and like Dijkstra’s, it’s a complete search which always finding a best solution. Read this to get better explanation.

My team agreed to use Manhattan distance to estimate distance between the current state and the goal state (h) and count the number of step as exact cost (g).

## Implementation

I wrote the code using Python. And after several hours coding I found python have a “magical” function that make easy to write 🙂 My first implementation was not using any class at all and it made the code hard to read. After I saw this implementation, I realize that code is much prettier than mine, so I rewrite my code using Node class with similar class concept from that code.

See the complete source code on Github