"rn" -> "m"
"cl" -> "d"
"ci" -> "a"
"vv" -> "w"
"Il" -> "ll"
"1" -> "l"
"I" -> "l"
"nn" -> "m"
"M0N" -> "MON"
"rn" -> "m"
"cl" -> "d"
"ci" -> "a"
"vv" -> "w"
"Il" -> "ll"
"1" -> "l"
"I" -> "l"
"nn" -> "m"
"M0N" -> "MON"
Switch to a working folder:
# cd /usr/local/sbin
Show what kernel my VPC owns:
# uname -a
Linux demonalex-VirtualBox 7.0.0-14-generic #14-Ubuntu SMP PREEMPT_DYNAMIC Mon Apr 13 11:09:53 UTC 2026 x86_64 GNU/Linux
Install llmster:
# curl -fsSL https://lmstudio.ai/install.sh | bash
Add the following into /etc/profile:
export PATH="/root/.lmstudio/bin:$PATH"
Open a new terminal and execute the following to see the model list:
# lms get
Press Ctrl+C to end the showing.
Download the model:
# lms get google/gemma-4-e2b
Check if the model has already been downloaded:
# lms ls
Have an interactive chatbot:
# lms chat
Type "/exit" can exit the chatbot conversation.
Install necessary plugin:
# curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
# echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
# apt-get update
# apt-get install docker-model-plugin
Pull:
# docker model pull ai/llama3.2
Run in Interactive mode:
# docker model run ai/llama3.2
Exit Interactive mode:
> /bye
Run in Single-prompt mode:
# docker model run ai/llama3.2 "Explain how Docker containers work in one sentence."
-----Failed to carry out from here:
Enable OpenAI mode:
# docker desktop enable model-runner --tcp 12434
Test OpenAI:
# curl http://localhost:12434/engines/v1/models
Remotely use through OpenAI:
# curl http://localhost:12434/engines/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "ai/llama3.2",
"messages": [{"role": "user", "content": "Hello!"}]
}'
#Add filter:
pktmon filter add MyFilter -i 192.168.215.11
#OR
pktmon filter add MyFilter -i 192.168.1.100 -p 443
pktmon filter add MyFilter -i 192.168.1.100 -p 443 -t tcp
#Start:
pktmon start --capture --log-mode real-time
#Stop:
pktmon stop
#Remove filter:
pktmon filter remove
Installation:
#apt-get update
#apt-get install tmux
How to use:
#tmux
Shortcut:
Ctrl+b c: creation
Ctrl+b x: Exit
Ctrl+b %: Split screen
Ctrl+b ;: Switch screen
### The Step-by-Step Process
1. **Run your Clusterer:**
* Go to the **Cluster** tab.
* Select **SimpleKMeans** and configure your (number of clusters).
* Run the algorithm. Ensure it completes successfully.
2. **Add the Labels via Filter:**
* Switch back to the **Preprocess** tab.
* Click **Choose** under the Filters section.
* Navigate to: `filters` -> `unsupervised` -> `attribute` -> **AddCluster**.
3. **Configure the Filter:**
* Click on the **AddCluster** text to open its configuration box.
* In the `clusterer` field, click "Choose" and select **SimpleKMeans** again (ensure the settings match what you used in the Cluster tab).
* Click **OK**.
4. **Apply and Save:**
* Click **Apply**. You will see a new attribute appear at the end of your attribute list, typically named "cluster."
* Click **Save...** to export your new labeled dataset as an `.arff` or `.csv` file.
---
### Pro-Tips for Labeling
* **The "Ignored" Attributes:** If you want to cluster based on certain features but keep an ID or Name column in the final file, make sure to use the `ignoredAttributeIndices` property within the SimpleKMeans settings inside the **AddCluster** filter.
* **Result Verification:** Before saving, you can click the **Edit...** button in the Preprocess tab to view the data table and confirm that the cluster assignments look correct (e.g., Cluster 0, Cluster 1, etc.).
---
#!/usr/bin/perl -w
use strict;
use warnings;
use PDL::LiteF;
use PDL::Stats;
# 1. Define 4 separate arrays (Features)
my $f1 = pdl(1, 2, 1, 10, 11, 12); # Feature 1
my $f2 = pdl(1, 1, 2, 10, 12, 11); # Feature 2
my $f3 = pdl(0, 1, 0, 15, 14, 15); # Feature 3
my $f4 = pdl(2, 2, 1, 20, 21, 22); # Feature 4
# 2. Combine them into a 4-column matrix
# cat() joins them, transpose() makes each row a "person/object"
my $data = cat($f1, $f2, $f3, $f4)->transpose;
# 3. Run K-means for 2 groups
my $k = 2;
my %result = $data->kmeans({k => $k, NCLUS => 2});
# 4. Display which group each of the 6 items belongs to
print "Data Matrix (Rows = Items, Cols = Features):\n$data\n";
print "Cluster Assignments:\n", $result{cluster}, "\n";
print "Final Centroids (The average of each group):\n", $result{centroid}, "\n";