Monday, August 18, 2025

Extending battery life in Linux

Extending battery life in Linux:

So, you want to extend your laptop battery life as much as possible.
One way is to avoid 100% charging of the battery.

We can easily configure this in Linux(my default OS) using tlp.

In case of RedHat distributions(Fedora, CentOS, RHEL):
sudo dnf install tlp tlp-rdw

Install tlp package:  (for Debian/Ubuntu distributions)
sudo apt install tlp tlp-rdw)

Enable and start it:
sudo systemctl enable tlp --now


Edit the config:
sudo vi /etc/tlp.conf

Find and set these values (ensure it is uncommented):
START_CHARGE_THRESH_BAT0=75
STOP_CHARGE_THRESH_BAT0=80

(This means charging will stop at 80%, and only resume if it drops below 75%.)

Restart tlp
sudo systemctl restart tlp

Verify the new values:
sudo tlp-stat -b
(This should display updated values).

Now, you can check how the discharge/recharge changes in your laptop battery.

Use Settings -> Power and enable % value for battery to check the values.

Thursday, August 14, 2025

Microsoft Gen AI course for beginners

https://microsoft.github.io/generative-ai-for-beginners/#/

https://github.com/microsoft/generative-ai-for-beginners/tree/main?tab=readme-ov-file#%EF%B8%8F-lessons

 

 

 

 

 

 

Friday, June 27, 2025

Google doc's tabs

 

I've just come across this new feature from google docs's tabs. 
This is something similar to tabs we use in browser.

 So we create a document which is aligned towards single topic.
In the same document we can have sub-topics under the single topic.
We can also have sub-sub topic inside :) 

--

Tabs in Google Docs let you create sections within a single document, similar to tabs in a web browser or spreadsheet. Each tab can contain separate content, allowing you to organize related information without switching between different Docs files.

Think of it like this:

  • Instead of having 5 separate Docs files for different aspects of a project, you can have 1 Google Doc with 5 tabs, each dedicated to a topic.

     

     Example:

    Let's say we have a AI project with main document name as "AI Assistant for Customer Support"

    We can have tabs as below:

    Tab Name What to Include
    1. Problem Statement Define the problem you're solving, pain points, target users, and project goals.
    2. Data Collection & Cleaning Sources of data (chat logs, support tickets), privacy considerations, preprocessing steps.
    3. Model Selection & Training ML/DL models considered (e.g., BERT, LLMs, custom models), training setups, experiments.
    4. Evaluation & Metrics Accuracy, F1 score, confusion matrix, user feedback — how you’ll judge model quality.
    5. Deployment Plan Architecture, inference setup (e.g., REST API), infrastructure (AWS/GCP), latency goals.
    6. UI/UX Design Interface mockups, chatbot UX, conversation flows.
    7. Risks & Ethical Concerns Bias, hallucinations, GDPR issues, response safety.
    8. Timeline & Milestones Sprint plans, deadlines, deliverables.
    9. Team & Roles Who’s doing what: ML engineer, designer, backend, QA, PM, etc.
    10. References & Tools Research papers, tech stack, tools used (e.g., Hugging Face, PyTorch, LangChain).


    This is awesome way to have a organized info.  Thanks Google.

    Thanks to ChatGPT for fetching an example.

Monday, June 9, 2025

Determine your graphical platform - X11/wayland

 

-- 

Open a terminal and run the command echo $XDG_SESSION_TYPE.

If the output is "x11", then your system is using X11.

If the output is "wayland", then your system is using Wayland.

Most modern systems make use of wayland.
--

Wayland:
A newer, more secure, and potentially more performant display protocol, especially for modern graphics hardware.

X11:
The traditional display server protocol used by many Linux systems, including Ubuntu.

--

Sunday, April 20, 2025

Education - simulation of concepts

 

Kids education:

https://phet.colorado.edu/

It covers the following:
Physics
Maths and statistics
Chemistry
Earth & Space
Biology

Simulations of concepts.