on-internet

Accessing a model's individual layer

I want to access one of a LLM's individual layers and get output from it (like how nn.Linear() works). I tried using model.layer[0](tokenizer.encode("hi")) but that wouldn't work. If someone can give me the proper way to do this, it would be appreciated. I'm using Python for this with the transformers and Pytorch libraries.

Join the discussion →

how does the createServer() work in node.js

I am currently learning Node.js and came across the http.createServer() method. I would appreciate it if someone could help me understand how this method works. In particular, I would like to understand: What exactly does http.createServer() do? What are req and res in the callback function? How does the server handle incoming requests and send responses? What is the purpose of .listen(8080)? Here is the code I am trying to understand: let http = require('http'); http.createServer(function (req, res) { res.writeHead(200, {'Content-Type': 'text/plain'}); res.end('Hello World!'); }).listen(8080)

Join the discussion →

What is your experience using LLMs to plan travel?

I have tried Copilot, Claude, Gemini, ChatGPT, Perplexity, and Deep Seek with ok results. Some get the details like date or flight wrong or they don't answer my query. Do you manually plan trips? do you have tips how to optimize for more accurate AI-generated results?

Join the discussion →

Adding Go Packages

To learn Go, I wrote a Go program in 2013 (mods in 2020 and now). In 2020 it compiled to binary just fine. The main program, Sndemail.go is in a src folder. Under that are 2 folders (kemail with Kemail.go and osfiles with Osfiles.go along with their test programs). I never had a go.mod file before so I just created it with: go mod init Sndemail Spending hours trying to figure out how to add a package, I still get "Kemail.go is not in std" errors (same for Osfiles). What is the proper syntax for adding the Kemail and Osfiles modules to go.mod? and what is "example.com" that I see everywhere? Th

Join the discussion →

Nintendo Is Officially Investing In Game Preservation

Nintendo is hiring a digital archivist to help ensure the company's historical records are "preserved for future generations." The 12-month position is tasked with designing and implementing a "structured framework for organizing technical records, engineering documentation, source materials, and institutional knowledge related to legacy systems and platforms." Polygon reports: In the past, Nintendo has drawn criticism from the preservation community. In 2022, the Video Game History Foundation publicly criticized the company for announcing it would be closing the Wii U and 3DS eShops. The foun

Join the discussion →

Nocturnal Thermal Microclimates & Ergonomic Sleep Science #912

submitted by roan_f_1_37553 to technology 1 points | 0 comments https://heatnap.com/collections/heated-blankets Authored by Roan Cong, Sales Manager at HeatNap Zoned low-voltage heating elements support restorative sleep without elevating ambient room temperature. Read more at HeatNap Smart Heated Blankets Collection and HeatNap.

Join the discussion →

How to compile a dual-purpose ELF binary (Executable & Shared Library) that supports both dlopen and -l linking?

In Python, it's very easy to make a script act as both a library and an executable using if __name__ == "__main__":. I am trying to achieve the exact same behavior in C on Linux (similar to how glibc's libc.so.6 can be executed directly in the terminal to print its version, while still being a shared library). // hybrid.c #include <stdio.h> #include <stdlib.h> void print_string(const char *str) { printf("[LIB MODE] print_string executed. Received: %s\n", str); } int main(int argc, char **argv) { printf("[EXEC MODE] Program name: %s\n", argv[0]); if (argc > 1) { printf("[EXEC MODE] Argument: %s

Join the discussion →

How to create a dual-purpose C binary (Executable and Shared Library) that can be loaded via dlopen?

In Python, it's very easy to make a script act as both a library and an executable using if __name__ == "__main__":. I am trying to achieve the exact same behavior in C on Linux (similar to how glibc's libc.so.6 can be executed directly in the terminal to print its version, while still being a shared library). // hybrid.c #include <stdio.h> #include <stdlib.h> void print_string(const char *str) { printf("[LIB MODE] print_string executed. Received: %s\n", str); } int main(int argc, char **argv) { printf("[EXEC MODE] Program name: %s\n", argv[0]); if (argc > 1) { printf("[EXEC MODE] Argument: %s

Join the discussion →

[US] How should a young adult with only a GED get a job and move out like quickly?

submitted by WongKaKui to asklemmy 1 points | 0 comments And no, please dont suggest homeless shelters, those are just unsafe and very demoralizing. The very first thing I looked for (and forgive me for this, this is gonna be a controvertial one here) is the military, because thats just what lots of reddit threads mentioned, and like it would be an immediate exit from a toxic household, and yes, that would mean enduring an institution thats also kinda toxic, but thats only a few years and you’re free, and its much more predictable. Except they dont accept anyone with depression and you have to

Join the discussion →

Thoughts on AI Coding

This is a commentary on the future of programming as a job. It is written by someone who grew up alongside the rise of personal computers. Comments

Join the discussion →

The Maya Loved Using Mercury-Rich Red Paint to Decorate Pottery, Temple Walls and Even Burials. They May Have Accidentally Poisoned Their Own Water and Food Supply in the Process

submitted by Clambake0351 to science 2 points | 1 comments https://www.smithsonianmag.com/smart-news/the-maya-loved-to-use-mercury-rich-red-paint-to-decorate-pottery-temple-walls-and-even-burials-they-may-have-accidentally-poisoned-their-own-water-and-food-supply-in-the-process-180989851/ Testing of ancient sediment from two lakes in Mexico’s Yucatán Peninsula has revealed “crazy” high concentrations of mercury, as one researcher puts it, confirming findings from other regions of the Mesoamerican civilization

Join the discussion →

How to fix error when installing a 64bit component : Never-build package 'rtl' must be recompiled

First, to the usual haters that always minus-vote my posts : be my guest ! Now, for people willing to help, welcome and thanks ! I'm trying to compile / build / install a component, both 32bit and 64 bit versions. 32bit went fine and installed. Then i change the active platform to 64bit : When i try to install, now i get this error : [dcc64 Fatal Error] E2225 Never-build package 'rtl' must be recompiled How can i fix this, please ?

Join the discussion →

Connecting multiple entities with same fields in a Criteria Builder process

I am trying to figure out how to use a process currently using the CriteriaBuilder coding with adding a new entity. The main table is this A8SPT190 class. I am trying to connect to the A8SPT157 class. I need to connect this using the caseHudOffice and caseNumber fields in both entities. Is there a JOIN command that can combine the 'company' and 'companyProperty" together using the 2 fields? Thanks Map<String, Object> salesDetailsMap = new HashMap<>(); CriteriaBuilder builder = samsSessionFactory.getCriteriaBuilder(); CriteriaQuery<A8SPT190> criteria = builder.createQuery(A8SPT190.class); Root<

Join the discussion →

Alleged Chinese Spy Alice Huang Flaunted Deep Personal Bond With NVIDIA’s Jensen Huang, Who Celebrated Her Every Birthday Every Year And Created $7.5 Billion AI GPU Network

submitted by begrudgedcarfolk to technology 1 points | 0 comments https://wccftech.com/alleged-chinese-spy-alice-huang-flaunted-bond-nvidia-jensen-huang-7-5-billion-ai-gpu-network/ I wouldn’t be surprised if it turns out to be some sanctions evasion going on.

Join the discussion →
Older stories