
Building https://xitter.gq/t.co/EYNLqmVv6p | Ex-CEO @Skillate_lab (Acquired by SenseHQ)
San Francisco, CA
Joined August 2010
- Tweets327
- Following902
- Followers133
- Likes2K
Bipul Vaibhav retweeted
Wow! "Attention is All You Need" (i.e., Transformers) was inspired by the Alien's communication style in the movie Arrival.
Readers added context they thought people might want to know
This is an error.
The podcast got this story wrong. Arrival was not an inspiration for self-attention/the transformer, it was however used as an analogy.
bsky.app/profile/victor…
bsky.app/profile/tilman…
Bipul Vaibhav retweeted
# explaining llm.c in layman terms
Training Large Language Models (LLMs), like ChatGPT, involves a large amount of code and complexity.
For example, a typical LLM training project might use the PyTorch deep learning library. PyTorch is quite complex because it implements a very general Tensor abstraction (a way to arrange and manipulate arrays of numbers that hold the parameters and activations of the neural network), a very general Autograd engine for backpropagation (the algorithm that trains the neural network parameters), and a large collection of deep learning layers you may wish to use in your neural network. The PyTorch project is 3,327,184 lines of code in 11,449 files.
On top of that, PyTorch is written in Python, which is itself a very high-level language. You have to run the Python interpreter to translate your training code into low-level computer instructions. For example the cPython project that does this translation is 2,437,955 lines of code across 4,306 files.
I am deleting all of this complexity and boiling the LLM training down to its bare essentials, speaking directly to the computer in a very low-level language (C), and with no other library dependencies. The only abstraction below this is the assembly code itself. I think people find it surprising that, by comparison to the above, training an LLM like GPT-2 is actually only a ~1000 lines of code in C in a single file. I am achieving this compression by implementing the neural network training algorithm for GPT-2 directly in C. This is difficult because you have to understand the training algorithm in detail, be able to derive all the forward and backward pass of backpropagation for all the layers, and implement all the array indexing calculations very carefully because you don’t have the PyTorch tensor abstraction available. So it’s a very brittle thing to arrange, but once you do, and you verify the correctness by checking agains PyTorch, you’re left with something very simple, small and imo quite beautiful.
Okay so why don’t people do this all the time?
Number 1: you are giving up a large amount of flexibility. If you want to change your neural network around, in PyTorch you’d be changing maybe one line of code. In llm.c, the change would most likely touch a lot more code, may be a lot more difficult, and require more expertise. E.g. if it’s a new operation, you may have to do some calculus, and write both its forward pass and backward pass for backpropagation, and make sure it is mathematically correct.
Number 2: you are giving up speed, at least initially. There is no fully free lunch - you shouldn’t expect state of the art speed in just 1,000 lines. PyTorch does a lot of work in the background to make sure that the neural network is very efficient. Not only do all the Tensor operations very carefully call the most efficient CUDA kernels, but also there is for example torch.compile, which further analyzes and optimizes your neural network and how it could run on your computer most efficiently. Now, in principle, llm.c should be able to call all the same kernels and do it directly. But this requires some more work and attention, and just like in (1), if you change anything about your neural network or the computer you’re running on, you may have to call different kernels, with different parameters, and you may have to make more changes manually.
So TLDR: llm.c is a direct implementation of training GPT-2. This implementation turns out to be surprisingly short. No other neural network is supported, only GPT-2, and if you want to change anything about the network, it requires expertise. Luckily, all state of the art LLMs are actually not a very large departure from GPT-2 at all, so this is not as strong of a constraint as you might think. And llm.c has to be additionally tuned and refined, but in principle I think it should be able to almost match (or even outperform, because we get rid of all the overhead?) PyTorch, with not too much more code than where it is today, for most modern LLMs.
And why I am working on it? Because it’s fun. It’s also educational, because those 1,000 lines of very simple C are all that is needed, nothing else. It's just a few arrays of numbers and some simple math operations over their elements like + and *. And it might even turn out to be practically useful with some more work that is ongoing.
This post is from an account that no longer exists. Learn more
Bipul Vaibhav retweeted
* Language is low bandwidth: less than 12 bytes/second. A person can read 270 words/minutes, or 4.5 words/second, which is 12 bytes/s (assuming 2 bytes per token and 0.75 words per token). A modern LLM is typically trained with 1x10^13 two-byte tokens, which is 2x10^13 bytes. This would take about 100,000 years for a person to read (at 12 hours a day).
* Vision is much higher bandwidth: about 20MB/s. Each of the two optical nerves has 1 million nerve fibers, each carrying about 10 bytes per second. A 4 year-old child has been awake a total 16,000 hours, which translates into 1x10^15 bytes.
In other words:
- The data bandwidth of visual perception is roughly 16 million times higher than the data bandwidth of written (or spoken) language.
- In a mere 4 years, a child has seen 50 times more data than the biggest LLMs trained on all the text publicly available on the internet.
This tells us three things:
1. Yes, text is redundant, and visual signals in the optical nerves are even more redundant (despite being 100x compressed versions of the photoreceptor outputs in the retina). But redundancy in data is *precisely* what we need for Self-Supervised Learning to capture the structure of the data. The more redundancy, the better for SSL.
2. Most of human knowledge (and almost all of animal knowledge) comes from our sensory experience of the physical world. Language is the icing on the cake. We need the cake to support the icing.
3. There is *absolutely no way in hell* we will ever reach human-level AI without getting machines to learn from high-bandwidth sensory inputs, such as vision.
Yes, humans can get smart without vision, even pretty smart without vision and audition. But not without touch. Touch is pretty high bandwidth, too.
Bipul Vaibhav retweeted
The reserve day is just to finish the rest of the 26 overs of Indian batting, and then it will rain again.
Bipul Vaibhav retweeted
Homi . J. Bhabha , Father of India's Nuclear Programme .
He Never Got Bharat Ratna Award But He Is Bharat Ratna In True Sense
Bipul Vaibhav retweeted
.@elonmusk, Yoshua Bengio, and thousands of other experts have signed a letter calling to halt the training of AI models that are more powerful than GPT-4.
What are ERNIE Bot's thoughts on this topic? Your thoughts? ⬇️
#ArtificialIntelligence #AI #GenerativeAI
Bipul Vaibhav retweeted
GPT4 is capable of turning a picture of a napkin sketch to a fully functioning html/css/javascript website.
Bipul Vaibhav retweeted
Google announces Bard, their ChatGPT competitor.
👏👏👏
blog.google/technology/ai/ba…
Bipul Vaibhav retweeted
Dynamic programming, developed by Richard Bellman in the 1950s, is a powerful algorithm design technique to solve problems by:
- Breaking them down into smaller problems
- Storing their solutions
- Combining these to get to the solution of the original problem
Bipul Vaibhav retweeted
This is a frightening visual for me.
The first dot is the amount of data Chat GPT 3 was trained on.
The second is what chat GPT 4 is trained on.
They are already doing demos.
It can write a 60,000 word book from a single prompt.
The only question I've had about AI…
Bipul Vaibhav retweeted
This is how Japan left their dressing room after their historic win over Germany yesterday.
They also left behind 11 origami cranes, a symbol of honour ❤️🇯🇵
Bipul Vaibhav retweeted
1987 :: Live Telecast of Cricket Match Without Any Interruption On Doordarshan
Bipul Vaibhav retweeted
A mini-cam hooked on to this magnificent bird allows us to literally get a ‘bird’s eye view.’ I find it useful to start a week by trying to always start with the big picture instead of getting bogged down in the nitty-gritty right away #MondayMotivation
Bipul Vaibhav retweeted
Some population data.
Chennai: 5 million (1990) to 11.5.million (2022)
Bengaluru: 4 million (1990) to 13 million (2022)
Over 30 years, Chennai added 6.5 million people, Bengaluru added 9 million.
Singapore has only 6 million people in total.
How can infrastructure keep up?
Bipul Vaibhav retweeted
1) This guide from @ycombinator is a bible for building products, with lessons on product-market fit, how to talk to users, MVPs, pivoting, growth and much more.
If you want just one guide this is the one to go.
ycombinator.com/library?cate…
Bipul Vaibhav retweeted
"Most people in the world are operating under the false impression that we've got too many people. This is not true. Earth could maintain a population many times the current level. The birth rate has been dropping like crazy." — @elonmusk
Bipul Vaibhav retweeted
Weekend research results.
30/72 companies in the @BessemerVP Emerging Cloud Index have at least one of:
Indian CEO
Indian CTO/CIO
>10% of headcount in 🇮🇳
No other country is close. The interconnection between the 🇺🇸/🇮🇳 tech ecosystems is deep, growing and crucial for both.































