HU, Pilihash.hupili.net·Apr 27, 2024Recommender System by GCP Vector SearchRecommender system has never been so easy and versatile given the latest development of AI. The new paradigm are just two folds. Turn everything into a vector, aka embedding. For example, one can use GPT to embed text; one can use CLIP to embed text...Discusspost
HU, Pilihash.hupili.net·Apr 26, 2024Chat with any file using GeminiThe latest interface of Gemini Pro supports to send a sequence of interlaced text / files as input (aka parts). The raw JSON API is convenient and straightfoward. One can wrap a utility function in 20 lins of codes. Utility function import requests ...Discusspost
HU, Pilihash.hupili.net·Apr 26, 2024Quick Restyling with Stable Diffusion and Control Net on MacI'm using Mac M1 2021 version. The steps to bring up the UI: Clone ConfyUI . Setup accelerated pytorch on Mac. Download SD-XL, and put the files under models/checkpoints. I chose sd_xl_turbo_1.0.safetensors. Download vae and put the files under m...Discusspost
HU, Pilihash.hupili.net·Mar 6, 2024Running EnvelopeRunning Envelope The running envelope is formed by combining a scatter plot with the Peter Riegel formula as an upper bound. With the running envelope, we can track the average speed that athletes can actually achieve under different (equivalent) dis...Discusspost
Giver KdkforGiver's NodeJS Bloggiver-node.hashnode.dev·Jan 16, 2024Node.js: HTTP ModuleWhat is this HTTP all about? The 'http' that we use as a module is actually a protocol which allows data exchange between client and server. As discussed before, 'http' is a built-in module in Node.js. It has 2 types of messages: HTTP Request and HT...Discusshttp
HU, Pilihash.hupili.net·Dec 28, 2023The Three Phase of InfluenceThe framework The three phase of influence framework applies in many scenarios. I'm going to tell you what it is in the original form and how to apply it in other scenarios. I firstly learned it from a public speaking workshop. There are three steps ...Discusspost
HU, Pilihash.hupili.net·Dec 20, 2023Solve Urban Orienteering Challenge with Google Maps Platform Distance Matrix APITLDR: We raced in an urban orienteering challenge last Sunday and won a the male category champion with finish time 3:07. The female category champion led us by 7min, which is a huge margin to ensure them to be overall champion. I tried to construct ...Discuss·51 readspost
HU, Pilihash.hupili.net·Dec 8, 2023Let all be letThe var, let, const in modern Javascript can be confusing and can cause many logical errors in async environment. Changing all var to let often resolves the issue. Here is one quick example. Suppose we have a function that wait a random time and exec...Discusspost
HU, Pilihash.hupili.net·Nov 25, 2023Python password generator one-linerFollowing are the one-liner and execution samples: >>> import random >>> import string >>> ''.join(map(lambda x: random.choice(string.ascii_lowercase + string.ascii_uppercase + string.digits), range(6))) 'DbtmlV' >>> ''.join(map(lambda x: random.cho...Discusspost
Red Terminalredterminal.hashnode.dev·Nov 24, 2023What is this Preflight request which is triggered along with REST calls ?My Notice: During software development, i have noticed an OPTIONS request is been sent for all kinds of complex requests (requests with custom headers). This type of request is a Preflight request. But not sure how its getting triggered and why, what...Discusspreflight