Ad

Friday, September 25, 2020

Firebase Tutorial - Cool things you can do with Firebase 2020

Introduction to Firebase

You control your Firebase using the Firebase console.

The console manage one or many projects. 

Each data resource in each project is called a collection. Like a collection of data. Read the firebase best practice article for better understanding of firebase projects. 

You can add apps to the firebase project. 


What is firebase : Online, in the cloud, real time database backed by Google and integrated into Google Cloud

Firebase works on all platforms

Provides iOS SDK, Android SDK, Web SDK

Full list of language and libraries found on its documentation: full list of SDK https://firebase.google.com/docs/database/rest/start

Language Libraries
Clojure taika by Cloudfuji
Dart IO Client in the official firebase-dart library
Go Firego by Steven Berlanga and Tim Gossett
Go Firebase by Cosmin Nicolaescu and Justin Tulloss
Java firebase4j by Brandon Gresham
Perl Firebase-Perl by Kiran Kumar and JT Smith
PHP firebase-php by kreait
firebase-php by Tamas Kalman
Python Pyrebase by James Childs-Maidment
python-firebase by Özgür Vatansever
python-firebase by Michael Huynh
Ruby firebase-ruby by Oscar Del Ben
BigBertha by Fernand Galiana
rest-firebase by Codementor


Even an admin SDK for administrative access. 

Firebase and google cloud

Can add Firebase to an existing GCP project

Use Firebase API to programmatically manage a firebase project. 

Firebase works Google Analytics and other offerings of the Google Cloud.
Fire Hosting is also available

Implement Search Functionality in Firebase Firestore
Use the query function to do SQL like filtering. 
However, Firestore does not natively support search. Instead it recommends using Algolia a search as a service platform. Algolia requires you to upload all your data to Algolia in order to make search possible. Though the term of service seems to say A cannot compete with you, you do have to expose your data to a 3rd party, it is a bit of a tie-down. The plus side is Algolia provides search UI, one click demo generation, so you can implement a prototype fast.  

Friday, September 18, 2020

Algolia Search API Basics Tutorial

I write full time now for hi@uniqtech.co write me to say hi, request content or be notified of new tutorials like this. Unqitech writes about all the cool technologies.

  • In short Algolia is search engine SaaS software as a service
  • Tables and records in the database 
  • There is a search bar which lets you test out the Algolia service right away. And it is easy. 
  • The search results will be highlighted (yay no code)
  • They have indices important attributes
  • To display an image, include an url to image, hosted for example on google cloud
  • Note you must upload your data to Algolia for this to work
  • In the term of use it seems Algolia have a non-compete clause which theoretically prevents them from making a clone of your app
  • I have not found a way to white label it
  • The price is reasonable, based on requests. 
  • It is super easy to use, build a demo site, share it with users! But it has Algolia label everywhere. You will be doing free ad for them. 
  • Remember don't put sensitive data here. Especially not HIPAA sensitive stuff. You will have to upload your data to Algolia for the search to work. 
  • You can upload your data using a JSON file or using the dashboard. One is fast one is easy to use. Remember to use a JSONLint to check for mistakes. 
  • Will save you time if you use a lint. 
  • Remember your data is not private to any online JSON lint you use.
  • Pricing : hacker plan available, free for certain quotas. Great for testing, hackathon. 
  • Example UI is available, again not white labeled.
  • Example codes are available. Again the logo appears in the input box :(
  • Easy configuration. 
  • You can get to search in minutes! That's easy. That's a true SaaS
  • You can easily configure auto-completion. 
  • The search is typo resistant. But when the database is small, auto completion and typo handling didn't work for me. 

Wednesday, September 2, 2020

Getting started with Scikit Learn Machine Learning API - read documentat...





In this video, posted with permission, we talk about the code pattern to get started with Scikit Learn and how to read the sklearn documentation.

Thursday, July 23, 2020

AutoML Automatic Machine Learning landscape

  • Features: here are some features that may be offered
    • Automatic visualization: Automatically generate visualizations
    • Machine learning interpretability (possibly advanced feature)
      • Explain model results
        • K-LIME, Shapley, Variable Importance, Decision Tree, Partial Dependence (H2O example)
    • Model Deployment and Operations
      • Automatic deployment
      • Create REST API endpoint

H2O Driverless AI
  •  Recipes available
  •     
    

Friday, June 12, 2020

Regularization in Machine Learning, Deep Learning

Regularization can prevent overfitting and potentially make algorithm converge faster and more performant. Useful in deep learning tasks, in neural networks. Regularization acts on the loss function (cost function) by adding an extra penalty term. The penalty term depending on the method of regularization, penalizing the weight parameters so it is a function of w

Two common regularization methods:
  • Lasso 
    • Uses L1-norm
  • Ridge
    • Uses L2-norm
A trick to remember the norm is that letter L comes before letter R, so Lasso is L1 norm and Ridge is L2 norm. 

One is more likely to result in sparse solutions turning one or more coefficients zero. Which one do you think it is? 

Quiz: which formula is Lasso? Which one is ridge?

  • Regularization penalizes overly complex models
  • Large weights usually make penalty term higher, so smaller effective weights are preferred
    • Larger weights cost more
  • Regularization = regular_loss_function + extra_penalty_term(lambda, weights)
    • The extra penalty term also depends on the weights parameter and the lambda rate parameter

Thursday, June 11, 2020

WeChat Basics


  • WeChat requires approval
  • Important to decouple app with data API so we can change more after
  • Where to host WeChat app? Best hosting best API?
  • 微信开发者工具 WeChat Developer Tools
    • 三个部分组成,模拟器,编辑器和调试器
  • Developer also need a wechat account to administer and manage wechat apps and login to developer tools. It is used constantly for login, verification and testing, so it's very important. It also is like a 2 factor authentication. It is often used to verify before logging in. 
  • index.js is the main page to write your code
  • WeChat Games
    • Amazing example viral game 跳一跳
  • Performance
    • Compressed images
    • Stored locally in geo locations
  • WeChat Mini Program with AR
    • Example Armani cosmetic app allows users to try makeup
    • Other use cases for WeChat AR including gaming, real estate house previewing, open house, hotel room previewing, house shopping
    • Limited API availability, only available for some brands and developers for AR
  • WeChat voice interface
  • WeChat is a platform, not just a messaging app, it also include e-commerce, game, web browsing, search and content publishing
  • Features
  • Can create a wechat test app, previously known as sandbox
  • To test your app, click on preview on iphone to use your iphone to scan a QR code and be able to test it on your local phone
Write HelloWorld in WeChat Mini Program
When the wechat mini program launches, the onLoad function will be invoked. In index.js this code will console.log hello world. As you can see the syntax is very much similar to JavaScript and is stored in a .js script file. 

Page({

  onLoad() {

    console.log("Hello World!")

  } 

})


onLoad is a lifecycle call back function



Making WeChat Stickers - Sticker Developer
It's very important to follow community guideline and developer policies. Here's the content requirement for WeChat

Linear Algebra Review

A matrix is a grid of number

Points and vectors

||w|| length of w, also known as the magnitude of w, also the L2 norm.

U(U^T) square value of matrix is matrix U multiply by the transpose of U


Firebase Tutorial - Cool things you can do with Firebase 2020

Introduction to Firebase You control your Firebase using the Firebase console. The console manage one or many projects.  Each dat...