Creating an Algorithm

Creating an Algorithm

After logging in to Algorithmia.com, click the "Create New" box in the upper-right, and pick "Algorithm". Here, you decide what to name it and what language you'll be working in, plus a few other options. Some of these options (open source, GPU, Licensing, Internet, and Pipelining) can be modified later if you change your mind, via the "manage" tab of your Algorithm's page.

Owner: usually, your algorithm will be created under your own username (algorithmia.com/algorithms/username/). However, if you are a member of an Organization, you can choose to place it under the org instead -- allowing you and other members of the org to edit and use it.

Algorithm Name: this should be a descriptive name based on what your algorithm does, such as "Document Classifier" or "Sentiment Analysis". It will also be used to create the URL of your algorithm as well (such as algo://username/DocumentClassifier).

Language: pick the language you prefer to write your function in. Note that this does not affect which languages you can call it from: regardless of your Algorithm's language, it can always be called from any other language.

Packageset: If you picked a "beta" language, you'll get a new set of options called "packagesets". These have certain libraries (such as TensorFlow or PyTorch) preinstalled for you, and come with some boilerplate code to make getting started easier. These are provided for convenience, but are not mandatory -- you can choose to pick a non-Beta version and manually specify any library if you prefer (we'll see how to do this later).

Open/Closed Source: you can choose to make your source code visible to anyone who has permission to see the Algorithm, or pick "closed source" so only you can see the code. Note that you can still make it possible for others to call your Algorithm, even if they can't see the code (we'll discuss this in under "publishing" later).

License: you can go with the standard Algorithmia License, or pick another popular one such as Apache, GNU, or MIT. Note that you are not transferring ownership of your code to Algorithmia: it is your code, we simply need your permission to run it for you.

Internet Access: turn this on if you need to need to read or write data from the public web (for example, allowing it to read information from an http:// URL), or if you need to install dependencies from a github repository.

Pipelining: one of the more powerful features of Algorithms is their ability to call other Algorithms to help them out; for example, if my Algorithm will be pulling images from Imgur or Instagram, I can have it use SmartImageDownloader internally to get the actual image file instead of their HTML wrapper code. Turn this off if you don't want to be able to call other Algorithms from inside your own Algo.

Hardware: if you picked a "Beta" language, this option won't show (it is decided by which packageset you selected). Otherwise, check the "CUDA/GPU" box only if your code makes use of the GPU (for example, if you're using the "tensorflow-gpu" package for deep learning). There's no extra charge for GPU use, but selecting it when you don't need it can actually slow your Algorithm down, and consumes unnecessary resources.

When you're ready, hit the “Create New Algorithm” button on the bottom of the form, and proceed to the next lesson: editing your Algorithm.

 


NEXT