Member-only story

Predict on the survivors using a perceptron made with Jax

Crystal X
4 min readOct 8, 2023

--

In my last post, I wrote about how to create a perceptron from scratch in the Jax library. And that post can be found here:- https://tracyrenee61.medium.com/create-a-perceptron-from-scratch-with-jax-d2e5effabc3d

In this post I intend to put what was learned about the perceptron into a machine learning project. This project utilises the Titanic dataset because it is one of the more complicated ones to work with. If my other posts about Jax are being read, it can be seen the accuracy of each model as it pertains to the Titanic dataset. Some models work better than others, and the reader can see how well the perceptron works on this particular dataset.

I created the Jupyter Notebook using Google Colab, which is a free online Jupyter Notebook hosted by Google. Google Colab is a great platform to write code in Python, but its one drawback is the fact that it does not have an adequate undo function. Therefore, if code is accidentally overwritten or deleted, it will be necessary to go into the save history and see if it can be salvaged.

After I created the Jupyter Notebook, I imported the libraries that I would need to execute the program, being:-

  1. Pandas to create dataframes and process data,
  2. Jax to create the perceptron,
  3. Sklearn to provide machine learning functionality, and
  4. Matplotlib to visualise the data.

--

--

Crystal X
Crystal X

Written by Crystal X

I have over five decades experience in the world of work, being in fast food, the military, business, non-profits, and the healthcare sector.

No responses yet