Skip to main content

How I spend 5000$ in AWS in less than 24 hours

 

How did it happened?

I develop EdTech solutions, mainly mobile apps. I have mobile app “Competitive Exam Preparation” available on Android and iOS platform. It is an Entrance Exam Preparation app for AIIMS MBBS, CAT, CLAT-UG, CA CPT, GK, GEP, GATE, JEE-Main, MHT-CET, NDA & NA and NEET exam. It has vital questions from previous year’s papers. It is a free and easy to use educational app, containing 13000+ wide collections of MCQ with answers.


Many users of the app use this app for government exam preparation. One of the user asked for support of this app in regional language, primarily user asked support for “Hindi” language.

Research

So I started doing research on tools that will help me to convert English MCQs to Hindi.

First thing I looked at was Google Translate https://translate.google.co.in/


 

It was fast and accurate

Next I looked at Amazon Translate https://aws.amazon.com/translate/


 

Looked at batch translation job page and found it super easy to use.

All I needed to do was upload my data in file format specified in s3 and run asynchronous job (selecting source and destination language).


 

Execution

AWS batch translation was super easy, so I decided to use it to convert from English->Hindi.

I had my source data with 13000+ rows in JSON format, which I converted to .xlsx format (choose this format for conversion, so that it can be used to import to .sqlite database and use it in apps)


 

Converted all my 13000 questions with answers into single .xlsx file (Total input file size was less than 1.5MB).

Ran the asynchronous job on AWS translate for English->Hindi and got output in my s3 bucket (size of converted file was around 1.5 MB)

The job was executed very fast. I thought why not translate to all other regional languages of India? So I searched for “Marathi” In Target language window.


 

Created another Job with same source .xlsx file and this time selected Target Language as “Marathi”. Again same result, job was executed successfully and got my 13000 questions with answers in Marathi in .xlsx format.

Got excited, as this conversion was super fast and easy. Looked at all other Target languages option available and total 74 languages were available for translation.


 

 

I didn’t really needed all other translations for my app, but I thought there is no harm in having them ready in case we decide to release app in other languages.

So over next few hours I ran the same s3 input file and only changed target language option. After few hours now I had 74 translated .xlsx files available in my s3 bucket.

Why bill was so high?

When I executed all jobs, I made mistake of just counting number of rows in excel and size of excel (only 13000+ rows in excel and less than 1.5 MB size). Thing I forgot to look at, is how Amazon Translate charges for translation (which was clearly mentioned on home screen). Service charges 15$ per million input characters, on a pay-as-you-go basis.


 

 Bill was generated with below amount


 

331,621,756.000 Characters were processed within few hours.

What I forgot to calculate was number of characters per question and number of translations. So for simplicity, lets assume there were 345 characters per question.

So (13000 questions * 74 languages * 345 characters per question) comes out to be 331+million characters!

It was amazing to see AWS was able to process all this in matter of few hours.

I had never used AWS translate before in batch or real-time.

Lessons learned

If you are using a new cloud service, complete a POC with small subset. See results, specially see billing and then only run a large set.

Was I charged for 5000$? — No. I had credits available with AWS Activate provided by Indus OS. Also AWS team reached out immediately to see if i needed any further help or support!


 

Comments

Popular posts from this blog

मराठी रीती रिवाज- महाराष्ट्रातील सण, देवस्थाने, पूजा, आरत्या आणि बरीच माहिती

मराठी रीती रिवाज या जगाच्या पाठीवर, कुठल्याही ठिकाणचे लोकजीवन खुलून येण्यासाठी मुख्यत्वे करून त्या संस्कृती मधले सण, त्यांचे उत्सव यांचा खूपच मोठा वाटा आहे. दैनंदिन आयुष्य जगताना माणूस हा नेहमीच काहीतरी नवीन घडण्याची वाट पहात होता. माणसाच्या या सतत नाविन्याच्या आणि बदलाच्या ओढीने तो समारंभासाठी निमित्ते शोधत गेला.  त्या शोधातूनच सणवारांची निर्मिती झाली. हे सण, उत्सव नेहमीच सर्वाना एकत्र बांधून ठेवण्यात,  त्यातून एकात्मता साधण्यात खूपच  महत्वाचं कार्य करत आले आहे. आपल्या भारतात आपले सण,  उत्सव यांना खूपच महत्व आहे. आपली प्राचीन भारतीय संस्कृती हि नेहमीच अध्यात्माशी निगडित होती. भारतातील तेहतीस कोटी देव, त्यांच्याशी निगडीत असलेल्या पौराणिक कथा, निसर्गात सतत घडणारे बदल, ऋतुमान या सर्वांशी सांगड घालून विविध सणवार यांची निर्मिती झाली. जीवनाला अध्यात्म , भक्तिभावाचा स्पर्श देण्यासाठी सर्व सण उत्सवांना देवकल्पना , पौराणिक कथा-कल्पनांची जोड दिली गेली.  विशिष्ठ देवतेचं अधिष्ठान , श्रद्धा , भक्तिभाव , पूजा ,  व्रत ,   नैवेद्य इत्यादींची जोड दिल्यामुळे सण धार्मिक भावनेने ,   श्रद्धेने साजरे केले

Unique Facts on Aadhaar number And Aadhaar (Targeted Delivery of Financial and Other Subsidies, Benefits and Services) Act, 2016

          Unique Facts on Aadhaar number And Aadhaar (Targeted Delivery of Financial and Other Subsidies, Benefits and Services) Act, 2016   Aadhaar is an individual identification number issued by the Unique Identification Authority of India (UIDAI) on behalf of the Government of India to individuals for the purpose of establishing the unique identity of every single person. Unique Identification Authority of India (UIDAI) is responsible for the processes of enrolment and authentication of Aadhaar Card under Aaadhaar Act, 2016.  Its objective is to collect biometric and demographic data of residents, store them in a centralized database.  First Aadhaar number was launched in Maharashtra in the village of Tembli, on 29 September 2010. Ranjana Sonawne: 782474317884 become the first Indian to get the (UID) number (termed as Aadhaar) Each resident of India will receive 12-digit unique identify number called as Aadhaar.  This number will serve as a proof of identity

HOW MOBILE APP IS HELPFUL IN LEARNING LAW ?

Law App - A self-learning platform for Law . Technology has completely transformed our daily life in a best possible way. ‘ Mobile Phone ’ is a great example of such technology. With this Mobile, we can do so many activities, which were hard to believe few years back. In fact today’s generation prefers anything and everything handy i.e. on Mobile, because it is faster n absolutely easy to use. Majority of the businesses/sectors now use Mobile technology to keep pace with the highly competitive market. Mobile technology’s role in educational area is also very vital. Similarly entry of this technology in Legal space has very bright future. WHY YOU NEED A ‘LAW APP’ – THE LAW LEARNING APP : Average cost of Law book is bit expensive. Over the period of time these books needs to be updated & purchased again and again. These books are heavy & expensive as well. So, there has to be a better solution. That's where Rachit Technology steps in. Smart P