The Hundred-Page Language Models Book
Read it:
https://github.com/aburkov/theLMbook
Read it:
https://github.com/aburkov/theLMbook
#LLM #NLP #ML #AI #PYTHON #PYTORCH
https://t.iss.one/DataScienceM
๐4
Executable Code Actions Elicit Better LLM Agents
1 Feb 2024 ยท Xingyao Wang, Yangyi Chen, Lifan Yuan, Yizhe Zhang, Yunzhu Li, Hao Peng, Heng Ji
Paper: https://arxiv.org/pdf/2402.01030v4.pdf
Codes:
https://github.com/epfllm/megatron-llm
https://github.com/xingyaoww/code-act
Datasets: MMLU - GSM8K - HumanEval - MATH
https://t.iss.one/DataScienceTโ ๏ธ
1 Feb 2024 ยท Xingyao Wang, Yangyi Chen, Lifan Yuan, Yizhe Zhang, Yunzhu Li, Hao Peng, Heng Ji
Large Language Model (LLM) agents, capable of performing a broad range of actions, such as invoking tools and controlling robots, show great potential in tackling real-world challenges. LLM agents are typically prompted to produce actions by generating #JSON or text in a pre-defined format, which is usually limited by constrained action space (e.g., the scope of pre-defined tools) and restricted flexibility (e.g., inability to compose multiple tools). This work proposes to use executable Python code to consolidate LLM agents' actions into a unified action space (CodeAct). Integrated with a Python interpreter, CodeAct can execute code actions and dynamically revise prior actions or emit new actions upon new observations through multi-turn interactions. Our extensive analysis of 17 LLMs on API-Bank and a newly curated benchmark shows that CodeAct outperforms widely used alternatives (up to 20% higher success rate). The encouraging performance of CodeAct motivates us to build an open-source #LLM agent that interacts with environments by executing interpretable code and collaborates with users using natural language. To this end, we collect an instruction-tuning dataset CodeActInstruct that consists of 7k multi-turn interactions using CodeAct. We show that it can be used with existing data to improve models in agent-oriented tasks without compromising their general capability. CodeActAgent, finetuned from Llama2 and Mistral, is integrated with #Python interpreter and uniquely tailored to perform sophisticated tasks (e.g., model training) using existing libraries and autonomously self-debug.
Paper: https://arxiv.org/pdf/2402.01030v4.pdf
Codes:
https://github.com/epfllm/megatron-llm
https://github.com/xingyaoww/code-act
Datasets: MMLU - GSM8K - HumanEval - MATH
https://t.iss.one/DataScienceT
Please open Telegram to view this post
VIEW IN TELEGRAM
โค3๐3๐ฅ1๐1
#DataScience #MachineLearning #DeepLearning #Python #AI #MLProjects #DataAnalysis #ExplainableAI #100DaysOfCode #TechEducation #MLInterviewPrep #NeuralNetworks #MathForML #Statistics #Coding #AIForEveryone #PythonForDataScience
Please open Telegram to view this post
VIEW IN TELEGRAM
๐10โค2
๐ 2025 Top IT Certification โ Free Study Materials Are Here!
๐ฅWhether you're preparing for #Cisco #AWS #PMP #Python #Excel #Google #Microsoft #AI or any other in-demand certification โ SPOTO has got you covered!
๐ Download the FREE IT Certs Exam E-book:
๐ https://bit.ly/4lNVItV
๐ง Test Your IT Skills for FREE:
๐ https://bit.ly/4imEjW5
โ๏ธ Download Free AI Materials :
๐ https://bit.ly/3F3lc5B
๐ Need 1-on-1 IT Exam Help? Contact Now:
๐ https://wa.link/k0vy3x
๐ Join Our IT Study Group for Daily Updates & Tips:
๐ https://chat.whatsapp.com/E3Vkxa19HPO9ZVkWslBO8s
๐ฅWhether you're preparing for #Cisco #AWS #PMP #Python #Excel #Google #Microsoft #AI or any other in-demand certification โ SPOTO has got you covered!
๐ Download the FREE IT Certs Exam E-book:
๐ https://bit.ly/4lNVItV
๐ง Test Your IT Skills for FREE:
๐ https://bit.ly/4imEjW5
โ๏ธ Download Free AI Materials :
๐ https://bit.ly/3F3lc5B
๐ Need 1-on-1 IT Exam Help? Contact Now:
๐ https://wa.link/k0vy3x
๐ Join Our IT Study Group for Daily Updates & Tips:
๐ https://chat.whatsapp.com/E3Vkxa19HPO9ZVkWslBO8s
โค3
This media is not supported in your browser
VIEW IN TELEGRAM
NVIDIA introduces Describe Anything Model (DAM)
a new state-of-the-art model designed to generate rich, detailed descriptions for specific regions in images and videos. Users can mark these regions using points, boxes, scribbles, or masks.
DAM sets a new benchmark in multimodal understanding, with open-source code under the Apache license, a dedicated dataset, and a live demo available on Hugging Face.
Explore more below:
Paper: https://lnkd.in/dZh82xtV
Project Page: https://lnkd.in/dcv9V2ZF
GitHub Repo: https://lnkd.in/dJB9Ehtb
Hugging Face Demo: https://lnkd.in/dXDb2MWU
Review: https://t.ly/la4JD
a new state-of-the-art model designed to generate rich, detailed descriptions for specific regions in images and videos. Users can mark these regions using points, boxes, scribbles, or masks.
DAM sets a new benchmark in multimodal understanding, with open-source code under the Apache license, a dedicated dataset, and a live demo available on Hugging Face.
Explore more below:
Paper: https://lnkd.in/dZh82xtV
Project Page: https://lnkd.in/dcv9V2ZF
GitHub Repo: https://lnkd.in/dJB9Ehtb
Hugging Face Demo: https://lnkd.in/dXDb2MWU
Review: https://t.ly/la4JD
#NVIDIA #DescribeAnything #ComputerVision #MultimodalAI #DeepLearning #ArtificialIntelligence #MachineLearning #OpenSource #HuggingFace #GenerativeAI #VisualUnderstanding #Python #AIresearch
https://t.iss.one/DataScienceTโ
Please open Telegram to view this post
VIEW IN TELEGRAM
๐5
Forwarded from Machine Learning with Python
๐ฏ ุงุจุฏุฃ ุฑุญูุชู ุงูุงุญุชุฑุงููุฉ ูู ุงูุจุฑู
ุฌุฉ ู
ุน
#Python_Mastery_Course ๐
ูู ุชุฑุบุจ ุจุชุนูู ูุบุฉ ุงูุจุฑู ุฌุฉ ุงูุฃูุซุฑ ุทูุจูุง ูู ุงูุนุงูู ุ
ูู ุชุญูู ุจุงููุตูู ุฅูู ู ุฌุงูุงุช ู ุซู ุงูุฐูุงุก ุงูุงุตุทูุงุนูุ ุชุญููู ุงูุจูุงูุงุช ุฃู ุชุตู ูู ุงููุงุฌูุงุชุ
๐ข ูุฐู ุงูุฏูุฑุฉ ุฎูุตุตุช ูุชููู ููุทุฉ ุงูุทูุงูู ูุญู ุงูู ุณุชูุจู!
________________________________________
๐ ู ุงุฐุง ุณุชุชุนูู ูู ูุฐู ุงูุฏูุฑุฉุ
๐น ุงููุญุฏุฉ 1: ุฃุณุงุณูุงุช ุจุงูุซูู (ุงูู ุชุบูุฑุงุช โ ุฃููุงุน ุงูุจูุงูุงุช โ ุงูุนู ููุงุช โ ุฃุณุงุณูุงุช ุงูููุฏ)
๐น ุงููุญุฏุฉ 2: ุงูุชุญูู ูู ุณูุฑ ุงูุจุฑูุงู ุฌ (ุงูุดุฑูุท โ ุงูุญููุงุช โ ุฃูุงู ุฑ ุงูุชุญูู )
๐น ุงููุญุฏุฉ 3: ููุงูู ุงูุจูุงูุงุช (ููุงุฆู โ ููุงู ูุณ โ ู ุฌู ูุนุงุช โ Tuples)
๐น ุงููุญุฏุฉ 4: ุงูุฏูุงู (ุฅูุดุงุก โ ู ุนุงู ูุงุช โ ุงููุทุงู โ ุงูุชูุฑุงุฑ)
๐น ุงููุญุฏุฉ 5: ุงููุญุฏุงุช (Modules)
๐น ุงููุญุฏุฉ 6: ุงูุชุนุงู ู ู ุน ุงูู ููุงุช ูู ููุงุช CSV
๐น ุงููุญุฏุฉ 7: ู ุนุงูุฌุฉ ุงูุงุณุชุซูุงุกุงุช ุจุงุญุชุฑุงู
๐น ุงููุญุฏุฉ 8: ุงูุจุฑู ุฌุฉ ุงููุงุฆููุฉ (OOP)
๐น ุงููุญุฏุฉ 9: ุงูู ูุงููู ุงูู ุชูุฏู ุฉ:
โโโ ุงูู ููุฏุงุช (Generators)
โโโ ุงููุงุฆูุงุช ุงููุงุจูุฉ ููุชูุฑุงุฑ (Iterators)
โโโ ุงูู ุฒููุงุช (Decorators)
๐ก ุนูุฏ ุงูุชูุงุฆู ุณุชููู ูุงุฏุฑูุง ุนูู:
โ๏ธ ุจูุงุก ู ุดุงุฑูุน ุญููููุฉ ุจูุบุฉ ุจุงูุซูู
โ๏ธ ุงูุงูุชูุงู ุจุซูุฉ ุฅูู ู ุฌุงูุงุช ู ุชูุฏู ุฉ ู ุซู ุงูุฐูุงุก ุงูุงุตุทูุงุนู ูุชุญููู ุงูุจูุงูุงุช
โ๏ธ ุฃุชู ุชุฉ ุงูู ูุงู ูุงูุชุนุงู ู ู ุน ุงูุจูุงูุงุช ุจุงุญุชุฑุงู
๐ฅ ูุธุงู ุงูุฏูุฑุฉ:
โข ุจุซ ู ุจุงุดุฑ Live ู ุน ุงูู ุฏุฑุจ ุฏ. ู ุญู ุฏ ุนู ุงุฏ ุนุฑูู
โข ุฌู ูุน ุงูู ุญุงุถุฑุงุช ุณุชูุฑูุน ุนูู ุงูู ููุน ูุชุดุงูุฏูุง ูู ุงูููุช ุงูุฐู ููุงุณุจู
๐ ู ุฏุฉ ุงูุฏูุฑุฉ: 25 ุณุงุนุฉ ุชุฏุฑูุจูุฉ
๐ ุชุงุฑูุฎ ุงูุจุฏุงูุฉ:15- 6
๐ฐ ุฎุตู ููุญุฌุฒ ุงูู ุจูุฑ
ุชูุงุตู ุงูุขู ู ุน ุฐูุฑ ููุฏ ุงูุฏูุฑุฉ"001"
https://t.iss.one/Agartha_Support
#Python_Mastery_Course ๐
ูู ุชุฑุบุจ ุจุชุนูู ูุบุฉ ุงูุจุฑู ุฌุฉ ุงูุฃูุซุฑ ุทูุจูุง ูู ุงูุนุงูู ุ
ูู ุชุญูู ุจุงููุตูู ุฅูู ู ุฌุงูุงุช ู ุซู ุงูุฐูุงุก ุงูุงุตุทูุงุนูุ ุชุญููู ุงูุจูุงูุงุช ุฃู ุชุตู ูู ุงููุงุฌูุงุชุ
๐ข ูุฐู ุงูุฏูุฑุฉ ุฎูุตุตุช ูุชููู ููุทุฉ ุงูุทูุงูู ูุญู ุงูู ุณุชูุจู!
________________________________________
๐ ู ุงุฐุง ุณุชุชุนูู ูู ูุฐู ุงูุฏูุฑุฉุ
๐น ุงููุญุฏุฉ 1: ุฃุณุงุณูุงุช ุจุงูุซูู (ุงูู ุชุบูุฑุงุช โ ุฃููุงุน ุงูุจูุงูุงุช โ ุงูุนู ููุงุช โ ุฃุณุงุณูุงุช ุงูููุฏ)
๐น ุงููุญุฏุฉ 2: ุงูุชุญูู ูู ุณูุฑ ุงูุจุฑูุงู ุฌ (ุงูุดุฑูุท โ ุงูุญููุงุช โ ุฃูุงู ุฑ ุงูุชุญูู )
๐น ุงููุญุฏุฉ 3: ููุงูู ุงูุจูุงูุงุช (ููุงุฆู โ ููุงู ูุณ โ ู ุฌู ูุนุงุช โ Tuples)
๐น ุงููุญุฏุฉ 4: ุงูุฏูุงู (ุฅูุดุงุก โ ู ุนุงู ูุงุช โ ุงููุทุงู โ ุงูุชูุฑุงุฑ)
๐น ุงููุญุฏุฉ 5: ุงููุญุฏุงุช (Modules)
๐น ุงููุญุฏุฉ 6: ุงูุชุนุงู ู ู ุน ุงูู ููุงุช ูู ููุงุช CSV
๐น ุงููุญุฏุฉ 7: ู ุนุงูุฌุฉ ุงูุงุณุชุซูุงุกุงุช ุจุงุญุชุฑุงู
๐น ุงููุญุฏุฉ 8: ุงูุจุฑู ุฌุฉ ุงููุงุฆููุฉ (OOP)
๐น ุงููุญุฏุฉ 9: ุงูู ูุงููู ุงูู ุชูุฏู ุฉ:
โโโ ุงูู ููุฏุงุช (Generators)
โโโ ุงููุงุฆูุงุช ุงููุงุจูุฉ ููุชูุฑุงุฑ (Iterators)
โโโ ุงูู ุฒููุงุช (Decorators)
๐ก ุนูุฏ ุงูุชูุงุฆู ุณุชููู ูุงุฏุฑูุง ุนูู:
โ๏ธ ุจูุงุก ู ุดุงุฑูุน ุญููููุฉ ุจูุบุฉ ุจุงูุซูู
โ๏ธ ุงูุงูุชูุงู ุจุซูุฉ ุฅูู ู ุฌุงูุงุช ู ุชูุฏู ุฉ ู ุซู ุงูุฐูุงุก ุงูุงุตุทูุงุนู ูุชุญููู ุงูุจูุงูุงุช
โ๏ธ ุฃุชู ุชุฉ ุงูู ูุงู ูุงูุชุนุงู ู ู ุน ุงูุจูุงูุงุช ุจุงุญุชุฑุงู
๐ฅ ูุธุงู ุงูุฏูุฑุฉ:
โข ุจุซ ู ุจุงุดุฑ Live ู ุน ุงูู ุฏุฑุจ ุฏ. ู ุญู ุฏ ุนู ุงุฏ ุนุฑูู
โข ุฌู ูุน ุงูู ุญุงุถุฑุงุช ุณุชูุฑูุน ุนูู ุงูู ููุน ูุชุดุงูุฏูุง ูู ุงูููุช ุงูุฐู ููุงุณุจู
๐ ู ุฏุฉ ุงูุฏูุฑุฉ: 25 ุณุงุนุฉ ุชุฏุฑูุจูุฉ
๐ ุชุงุฑูุฎ ุงูุจุฏุงูุฉ:15- 6
๐ฐ ุฎุตู ููุญุฌุฒ ุงูู ุจูุฑ
ุชูุงุตู ุงูุขู ู ุน ุฐูุฑ ููุฏ ุงูุฏูุฑุฉ"001"
https://t.iss.one/Agartha_Support
Telegram
Agartha Support
Forwarded from Machine Learning with Python
๐ FREE IT Study Kits for 2025 โ Grab Yours Now!
Just found these zero-cost resources from SPOTO๐
Perfect if you're prepping for #Cisco, #AWS, #PMP, #AI, #Python, #Excel, or #Cybersecurity!
โ 100% Free
โ No signup traps
โ Instantly downloadable
๐ IT Certs E-book: https://bit.ly/4fJSoLP
โ๏ธ Cloud & AI Kits: https://bit.ly/3F3lc5B
๐ Cybersecurity, Python & Excel: https://bit.ly/4mFrA4g
๐ง Skill Test (Free!): https://bit.ly/3PoKH39
Tag a friend & level up together ๐ช
๐ Join the IT Study Group: https://chat.whatsapp.com/E3Vkxa19HPO9ZVkWslBO8s
๐ฒ 1-on-1 Exam Help: https://wa.link/k0vy3x
๐Last 24 HOURS to grab Mid-Year Mega Sale prices๏ผDonโt miss Lucky Draw๐
https://bit.ly/43VgcbT
Just found these zero-cost resources from SPOTO๐
Perfect if you're prepping for #Cisco, #AWS, #PMP, #AI, #Python, #Excel, or #Cybersecurity!
โ 100% Free
โ No signup traps
โ Instantly downloadable
๐ IT Certs E-book: https://bit.ly/4fJSoLP
โ๏ธ Cloud & AI Kits: https://bit.ly/3F3lc5B
๐ Cybersecurity, Python & Excel: https://bit.ly/4mFrA4g
๐ง Skill Test (Free!): https://bit.ly/3PoKH39
Tag a friend & level up together ๐ช
๐ Join the IT Study Group: https://chat.whatsapp.com/E3Vkxa19HPO9ZVkWslBO8s
๐ฒ 1-on-1 Exam Help: https://wa.link/k0vy3x
๐Last 24 HOURS to grab Mid-Year Mega Sale prices๏ผDonโt miss Lucky Draw๐
https://bit.ly/43VgcbT
Forwarded from Machine Learning with Python
๐ 2025 FREE Study Recourses from SPOTO for yโall โ Donโt Miss Out!
โ 100% Free Downloads
โ No signup / spam
๐ #Python, Cybersecurity & Excel: https://bit.ly/4lYeVYp
๐ #Cloud Computing: https://bit.ly/45Rj1gm
โ๏ธ #AI Kits: https://bit.ly/4m4bHTc
๐ #CCNA Courses: https://bit.ly/45TL7rm
๐ง Free Online Practice โ Test Now: https://bit.ly/41Kurjr
September 8th to 21th, SPOTO launches the Lowest Price Ever on ALL products! ๐ฅ
Amazing Discounts for ๐ CCNA 200-301 ๐ CCNP 400-007 and moreโฆ
๐ฒ Contact admin to grab them: https://wa.link/uxde01
โ 100% Free Downloads
โ No signup / spam
๐ #Python, Cybersecurity & Excel: https://bit.ly/4lYeVYp
๐ #Cloud Computing: https://bit.ly/45Rj1gm
โ๏ธ #AI Kits: https://bit.ly/4m4bHTc
๐ #CCNA Courses: https://bit.ly/45TL7rm
๐ง Free Online Practice โ Test Now: https://bit.ly/41Kurjr
September 8th to 21th, SPOTO launches the Lowest Price Ever on ALL products! ๐ฅ
Amazing Discounts for ๐ CCNA 200-301 ๐ CCNP 400-007 and moreโฆ
๐ฒ Contact admin to grab them: https://wa.link/uxde01
โค1
๐ก ViT for Fashion MNIST Classification
This lesson demonstrates how to use a pre-trained Vision Transformer (ViT) to classify an image from the Fashion MNIST dataset. ViT treats an image as a sequence of patches, similar to how language models treat sentences, making it a powerful architecture for computer vision tasks. We will use a model from the Hugging Face Hub that is already fine-tuned for this specific dataset.
Code explanation: This script uses the
#Python #MachineLearning #ViT #ComputerVision #HuggingFace
โโโโโโโโโโโโโโโ
By: @DataScienceT โจ
This lesson demonstrates how to use a pre-trained Vision Transformer (ViT) to classify an image from the Fashion MNIST dataset. ViT treats an image as a sequence of patches, similar to how language models treat sentences, making it a powerful architecture for computer vision tasks. We will use a model from the Hugging Face Hub that is already fine-tuned for this specific dataset.
from transformers import ViTImageProcessor, ViTForImageClassification
from datasets import load_dataset
import torch
# 1. Load a model fine-tuned on Fashion MNIST and its processor
model_name = "abhishek/autotrain-fashion-mnist-283834433"
processor = ViTImageProcessor.from_pretrained(model_name)
model = ViTForImageClassification.from_pretrained(model_name)
# 2. Load the dataset and get a sample image
dataset = load_dataset("fashion_mnist", split="test")
image = dataset[100]['image'] # Get the 100th image
# 3. Preprocess the image and prepare it for the model
inputs = processor(images=image, return_tensors="pt")
# 4. Perform inference to get the classification logits
with torch.no_grad():
outputs = model(**inputs)
logits = outputs.logits
# 5. Get the predicted class and its label
predicted_class_idx = logits.argmax(-1).item()
predicted_class = model.config.id2label[predicted_class_idx]
print(f"Image is a: {dataset[100]['label']}")
print(f"Model predicted: {predicted_class}")
Code explanation: This script uses the
transformers library to load a ViT model specifically fine-tuned for Fashion MNIST classification. It then loads the dataset, selects a single sample image, and uses the model's processor to convert it into the correct input format. The model performs inference, and the script identifies the most likely class from the output logits, printing the final human-readable prediction.#Python #MachineLearning #ViT #ComputerVision #HuggingFace
โโโโโโโโโโโโโโโ
By: @DataScienceT โจ
๐ก ViT for Fashion MNIST Classification
This lesson demonstrates how to use a pre-trained Vision Transformer (ViT) to classify an image from the Fashion MNIST dataset. ViT treats an image as a sequence of patches, similar to how language models treat sentences, making it a powerful architecture for computer vision tasks. We will use a model from the Hugging Face Hub that is already fine-tuned for this specific dataset.
Code explanation: This script uses the
#Python #MachineLearning #ViT #ComputerVision #HuggingFace
โโโโโโโโโโโโโโโ
By: @DataScienceT โจ
This lesson demonstrates how to use a pre-trained Vision Transformer (ViT) to classify an image from the Fashion MNIST dataset. ViT treats an image as a sequence of patches, similar to how language models treat sentences, making it a powerful architecture for computer vision tasks. We will use a model from the Hugging Face Hub that is already fine-tuned for this specific dataset.
from transformers import ViTImageProcessor, ViTForImageClassification
from datasets import load_dataset
import torch
# 1. Load a model fine-tuned on Fashion MNIST and its processor
model_name = "abhishek/autotrain-fashion-mnist-283834433"
processor = ViTImageProcessor.from_pretrained(model_name)
model = ViTForImageClassification.from_pretrained(model_name)
# 2. Load the dataset and get a sample image
dataset = load_dataset("fashion_mnist", split="test")
image = dataset[100]['image'] # Get the 100th image
# 3. Preprocess the image and prepare it for the model
inputs = processor(images=image, return_tensors="pt")
# 4. Perform inference to get the classification logits
with torch.no_grad():
outputs = model(**inputs)
logits = outputs.logits
# 5. Get the predicted class and its label
predicted_class_idx = logits.argmax(-1).item()
predicted_class = model.config.id2label[predicted_class_idx]
print(f"Image is a: {dataset[100]['label']}")
print(f"Model predicted: {predicted_class}")
Code explanation: This script uses the
transformers library to load a ViT model specifically fine-tuned for Fashion MNIST classification. It then loads the dataset, selects a single sample image, and uses the model's processor to convert it into the correct input format. The model performs inference, and the script identifies the most likely class from the output logits, printing the final human-readable prediction.#Python #MachineLearning #ViT #ComputerVision #HuggingFace
โโโโโโโโโโโโโโโ
By: @DataScienceT โจ
๐ค๐ง Reflex: Build Full-Stack Web Apps in Pure Python โ Fast, Flexible and Powerful
๐๏ธ 29 Oct 2025
๐ AI News & Trends
Building modern web applications has traditionally required mastering multiple languages and frameworks from JavaScript for the frontend to Python, Java or Node.js for the backend. For many developers, switching between different technologies can slow down productivity and increase complexity. Reflex eliminates that problem. It is an innovative open-source full-stack web framework that allows developers to ...
#Reflex #FullStack #WebDevelopment #Python #OpenSource #WebApps
๐๏ธ 29 Oct 2025
๐ AI News & Trends
Building modern web applications has traditionally required mastering multiple languages and frameworks from JavaScript for the frontend to Python, Java or Node.js for the backend. For many developers, switching between different technologies can slow down productivity and increase complexity. Reflex eliminates that problem. It is an innovative open-source full-stack web framework that allows developers to ...
#Reflex #FullStack #WebDevelopment #Python #OpenSource #WebApps
Top 100 Data Analyst Interview Questions & Answers
#DataAnalysis #InterviewQuestions #SQL #Python #Statistics #CaseStudy #DataScience
Part 1: SQL Questions (Q1-30)
#1. What is the difference between
A:
โข
โข
โข
#2. Select all unique departments from the
A: Use the
#3. Find the top 5 highest-paid employees.
A: Use
#4. What is the difference between
A:
โข
โข
#5. What are the different types of SQL joins?
A:
โข
โข
โข
โข
โข
#6. Write a query to find the second-highest salary.
A: Use
#7. Find duplicate emails in a
A: Group by the email column and use
#8. What is a primary key vs. a foreign key?
A:
โข A Primary Key is a constraint that uniquely identifies each record in a table. It must contain unique values and cannot contain NULL values.
โข A Foreign Key is a key used to link two tables together. It is a field (or collection of fields) in one table that refers to the Primary Key in another table.
#9. Explain Window Functions. Give an example.
A: Window functions perform a calculation across a set of table rows that are somehow related to the current row. Unlike aggregate functions, they do not collapse rows.
#10. What is a CTE (Common Table Expression)?
A: A CTE is a temporary, named result set that you can reference within a
#DataAnalysis #InterviewQuestions #SQL #Python #Statistics #CaseStudy #DataScience
Part 1: SQL Questions (Q1-30)
#1. What is the difference between
DELETE, TRUNCATE, and DROP?A:
โข
DELETE is a DML command that removes rows from a table based on a WHERE clause. It is slower as it logs each row deletion and can be rolled back.โข
TRUNCATE is a DDL command that quickly removes all rows from a table. It is faster, cannot be rolled back, and resets table identity.โข
DROP is a DDL command that removes the entire table, including its structure, data, and indexes.#2. Select all unique departments from the
employees table.A: Use the
DISTINCT keyword.SELECT DISTINCT department
FROM employees;
#3. Find the top 5 highest-paid employees.
A: Use
ORDER BY and LIMIT.SELECT name, salary
FROM employees
ORDER BY salary DESC
LIMIT 5;
#4. What is the difference between
WHERE and HAVING?A:
โข
WHERE is used to filter records before any groupings are made (i.e., it operates on individual rows).โข
HAVING is used to filter groups after aggregations (GROUP BY) have been performed.-- Find departments with more than 10 employees
SELECT department, COUNT(employee_id)
FROM employees
GROUP BY department
HAVING COUNT(employee_id) > 10;
#5. What are the different types of SQL joins?
A:
โข
(INNER) JOIN: Returns records that have matching values in both tables.โข
LEFT (OUTER) JOIN: Returns all records from the left table, and the matched records from the right table.โข
RIGHT (OUTER) JOIN: Returns all records from the right table, and the matched records from the left table.โข
FULL (OUTER) JOIN: Returns all records when there is a match in either the left or right table.โข
SELF JOIN: A regular join, but the table is joined with itself.#6. Write a query to find the second-highest salary.
A: Use
OFFSET or a subquery.-- Method 1: Using OFFSET
SELECT salary
FROM employees
ORDER BY salary DESC
LIMIT 1 OFFSET 1;
-- Method 2: Using a Subquery
SELECT MAX(salary)
FROM employees
WHERE salary < (SELECT MAX(salary) FROM employees);
#7. Find duplicate emails in a
customers table.A: Group by the email column and use
HAVING to find groups with a count greater than 1.SELECT email, COUNT(email)
FROM customers
GROUP BY email
HAVING COUNT(email) > 1;
#8. What is a primary key vs. a foreign key?
A:
โข A Primary Key is a constraint that uniquely identifies each record in a table. It must contain unique values and cannot contain NULL values.
โข A Foreign Key is a key used to link two tables together. It is a field (or collection of fields) in one table that refers to the Primary Key in another table.
#9. Explain Window Functions. Give an example.
A: Window functions perform a calculation across a set of table rows that are somehow related to the current row. Unlike aggregate functions, they do not collapse rows.
-- Rank employees by salary within each department
SELECT
name,
department,
salary,
RANK() OVER (PARTITION BY department ORDER BY salary DESC) as dept_rank
FROM employees;
#10. What is a CTE (Common Table Expression)?
A: A CTE is a temporary, named result set that you can reference within a
SELECT, INSERT, UPDATE, or DELETE statement. It helps improve readability and break down complex queries.โค2
โจGradio: Hassle-Free Sharing and Testing of ML Models in the Wild
๐ Summary:
Gradio is an open-source Python package that creates visual interfaces for ML models, making them accessible to non-specialized users via a URL. This improves collaboration by allowing easy interaction, feedback, and trust-building in interdisciplinary settings.
๐น Publication Date: Published on Jun 6, 2019
๐น Paper Links:
โข arXiv Page: https://arxiv.org/abs/1906.02569
โข PDF: https://arxiv.org/pdf/1906.02569
โข Github: https://github.com/gradio-app/gradio
๐น Models citing this paper:
โข https://huggingface.co/CxECHO/CE
โจ Datasets citing this paper:
โข https://huggingface.co/datasets/society-ethics/papers
โจ Spaces citing this paper:
โข https://huggingface.co/spaces/orYx-models/Nudge_Generator
โข https://huggingface.co/spaces/society-ethics/about
โข https://huggingface.co/spaces/mindmime/gradio
==================================
For more data science resources:
โ https://t.iss.one/DataScienceT
#Gradio #MachineLearning #MLOps #Python #DataScience
๐ Summary:
Gradio is an open-source Python package that creates visual interfaces for ML models, making them accessible to non-specialized users via a URL. This improves collaboration by allowing easy interaction, feedback, and trust-building in interdisciplinary settings.
๐น Publication Date: Published on Jun 6, 2019
๐น Paper Links:
โข arXiv Page: https://arxiv.org/abs/1906.02569
โข PDF: https://arxiv.org/pdf/1906.02569
โข Github: https://github.com/gradio-app/gradio
๐น Models citing this paper:
โข https://huggingface.co/CxECHO/CE
โจ Datasets citing this paper:
โข https://huggingface.co/datasets/society-ethics/papers
โจ Spaces citing this paper:
โข https://huggingface.co/spaces/orYx-models/Nudge_Generator
โข https://huggingface.co/spaces/society-ethics/about
โข https://huggingface.co/spaces/mindmime/gradio
==================================
For more data science resources:
โ https://t.iss.one/DataScienceT
#Gradio #MachineLearning #MLOps #Python #DataScience
arXiv.org
Gradio: Hassle-Free Sharing and Testing of ML Models in the Wild
Accessibility is a major challenge of machine learning (ML). Typical ML models are built by specialists and require specialized hardware/software as well as ML experience to validate. This makes...