#voice-chat-text-0

1 messages · Page 561 of 1

proud tangle
#

open() is available by default, and it reads text freely. But if you want something more complicated (word files, json files, reading a lot of files) you get a wrapper yeah

livid niche
#

but python doesnt mind printing plaintext files im guessing?

proud tangle
#

json, gzip, zipfile, csv etc are all builtin imports

livid niche
#

which is faster, using pyjq or starting a subprocess to invoke jq?

proud tangle
#

I've read word docs, pdfs, excel files

#

depends. Pyjq might do that internally

livid niche
#

pyjq is pythons implementation of jq

proud tangle
#

regardless, pyjq will be much nicer to use

livid niche
#

jq is the shell program you use

proud tangle
#

oh interesting.. pyjq is a C wrapper around jq

#

so definitely faster

livid niche
proud tangle
#

....

livid niche
#

whats happening with email

proud tangle
#

Well, technically, I'm not sure. You'd have to test. Practically, it shouldn't matter so much

#

The subprocess interface will suck, which is why pyjq exists

#

however despite all that

#

Please

#

for the love of god

#

Dont use

#

100gb json files

#

as dictionaries

#

holy fuck

#

stop

#

please

#

it's already dead

livid niche
proud tangle
#

These are the fucking 100gb excel files of our industry

#

no, stop, do not pass go

proud tangle
#

json is fine for anything below ~100mb

#

above that we have orjson or something, but above taht the answer is use something else

#

Python has a variety of deep storage modules, sqlite is good past several gigs, and past that use a real database

#

how do I pyut this

#

a database is not optional

#

once you have >100gb of data, you are using one

#

"but I'm using jq" it's a crappy database implementation

#

doing all the things a database does

somber heath
livid niche
livid niche
#

but i realize 100gb of text is insane

proud tangle
#

the builtin json probably handles it fine

#

you could drop in orjson and be certainly fine

livid niche
#

out of curiosity what is the best database implementation for storing primes though

#

ive been wanting to create a private collection of primes

#

only needing to look at one prime at a time i suppose

livid niche
#

like if i wanted to store 1 billion numbers

proud tangle
#

!e ```py
a = list(range(500_000))
import json, time

file = open("data.json", "w")

before = time.perf_counter()
json.dump(a, file)

after = time.perf_counter()
file.close()
print(after-before, "to dump")
file = open("data.json", "r")
before = time.perf_counter()
a = json.load(file)
after = time.perf_counter()
print(after-before, "to load")

file.seek(0)
print(len(file.read()))

wise cargoBOT
proud tangle
#

4mb takes .2s to save and 0.05 to load here

#

Yeah this sounds like something youd' want to use an HBM store for..

#

wrong abbreviation

livid niche
#

oh damn ive never heard of this ram
https://en.wikipedia.org/wiki/High_Bandwidth_Memory

High Bandwidth Memory (HBM) is a computer memory interface for 3D-stacked synchronous dynamic random-access memory (SDRAM) initially from Samsung, AMD and SK Hynix. It is used in conjunction with high-performance graphics accelerators, network devices, high-performance ASICs, as on-package cache or on-package RAM in CPUs, and FPGAs and in some s...

proud tangle
#

IT's a scientist thing

#

HDF5

#

this is your "my dataset doesn't fit in ram" storage tool

livid niche
proud tangle
#

You may also want to look into parquet

#

Also I actially did that!

#

I wrote a prime number calculator and ran it into the 100 billion range

#

I think

#

or low trillions

#

It ran out of ram and I had problems :3

#

wheel sieving?

proud tangle
#

ikr

livid niche
proud tangle
#

My main performance issues were:
printing each number
and reallocating the storage space

#

Primes are antiregular

livid niche
#

i once printed 1 million primes onto paper but i lost all my primes

#

😭

proud tangle
#

Lol

#

No, it actualyl cannot be

#

that's the trick

#

Primes are only defined as an absence of all other patterns

#

The current best generation method is to literally construct the patterns and extrapolate them and then look in the holes

#

IT's why they're fascinating

livid niche
#

the riemann zeta function is a good approximation

proud tangle
#

the number 7 :3

livid niche
#

it has yet to be proven/disproven

craggy vale
livid niche
#

@somber heath i think they might mean they dont know how to bake the icons into the actual system

proud tangle
#

lol

livid niche
#

@craggy vale im trying to figure out how to cross compile linux kernel to run on this tiny thing

#

it is the size of the tip of my finger

craggy vale
livid niche
proud tangle
#
livid niche
#

it powers the cardputer

proud tangle
#

ESP32-S3FN8

#

https://gojimmypi.github.io/ESP32-S3-Linux/ here's a random tutorial from google

#

I saw a few more

livid niche
#

i need to purchase PSRAM cuz the internal memory of the xtensa cpu on the chip is too tiny to fit linux kernel

proud tangle
#

The first company that figures out how to shrink ram again will be the richest fucks imaginable

livid niche
#

i printed hello world on that thing

somber heath
livid niche
proud tangle
#

You know what I want?

#

I want apple to stop being a bunch of fucks

#

and release their chips out

#

look at this crap

craggy vale
#

?this?

livid niche
proud tangle
#

this is an iphone air mainboard

#

it fits in a fucking thumbdrive

craggy vale
livid niche
proud tangle
#

imagine IOT constructed out fo these

#

it fits under the top of the phone

#

the wghole back of thephone has no chips, just a brace and a battery

proud tangle
#

call it a macrosd card and reuse nvme

livid niche
proud tangle
#

size example

livid niche
#

@craggy vale raspberry pi is like 300$, cardputer is 30$

proud tangle
#

if software enshittification wasn't going at maximum coal power

proud tangle
#

we coudl get a pi zero for 50 bucks and stick it in a keyboard and run normal things on it

#

but unfortunately we have to support microsoft teams

#

Imagine true modular computing

craggy vale
#

alright

ebon kite
#

@somber heath @mighty linden
gyz, leaving for 10-20 mints

somber heath
#

Take the cannula.

#

Cannoli are Sicilian pastries consisting of a tube-shaped shell of fried pastry dough, filled with a sweet and creamy filling containing ricotta cheese. Their size ranges from 9 to 20 centimetres (3+1⁄2 to 8 in). In mainland Italy, the food is commonly known as cannolo siciliano (lit. 'Sicilian cannoli').
In culinary traditions across Sicily...

austere hornet
#

hi

#

just popping in for a bit

#

very unstable wifi here though

#

i miss when it was green

#

very therapeutic

#

oh well

#

now i must away

whole bear
#

Why do older generations think younger generations are foolish?

somber heath
#

@tiny oyster 👋

tiny oyster
#

Apologies for intruding

whole bear
#

I mean the same mindset as class or capitalism.
Richer thinks the poor are foolish

peak siren
whole bear
paper wolf
#

🗣️ gu-knor

peak depot
#

Knorr

paper wolf
whole bear
#

English is Germanic language

paper wolf
#

ignore
igknorr

whole bear
#

Knorr gate

paper wolf
#

🗣️ ke-nees

paper wolf
#

opalmist use that

#

@crystal fox can i scrape it?

#

i can scrape it to get the jokes from that

#

ur late

#

my ke-nees hurt

#

the idea of intelectual properly was to create something, and make sure only you can take advantage of that creation in exchange of you share how you create it

#

now they add a rule so that there's a way to hide some details on how its done exactly

#

copop copy

mighty linden
#

I disagree

#

No you can't never

candid spire
#

It has been long time, I have to seen rabbit

#

Is he alive?

#

Are you sure he is?

paper wolf
#

no embed ._.

paper wolf
#

still no embed ._.

calm ginkgo
candid spire
#

Hello my friends

#

How are you?

calm ginkgo
#

Mechanistic interpretability (often abbreviated as mech interp, mechinterp, or MI) is a subfield of research within explainable artificial intelligence that aims to understand the internal workings of neural networks by analyzing the mechanisms present in their computations. The approach seeks to analyze neural networks in a manner similar to ho...

candid spire
#

Does it really matter to all of us to learn such things?

#

AI is not a bubble

#

It is next internet

#

AI based application can be bubble but not LLM itself

#

because we have limited LLM

#

biggest concern for leading AI company like OpenAI is energy and profitable business model.
Most people want almost free AI because they think robot cost no money.
OpenAI is dependent on US govenrment.
Without government it would have been out competed by Chinese LLM

paper wolf
#

@calm ginkgo what kind of AI you working on

candid spire
#

I hate those startup which make use of existing LLM as their main feature of product.

candid spire
#

I mean you have little to no inovation

calm ginkgo
paper wolf
paper wolf
candid spire
calm ginkgo
#

!pypi openskill

wise cargoBOT
#

Multiplayer Rating System. No Friction.

Released on <t:1750418728:D>.

paper wolf
#

using AI to rank what?

#

anything?

calm ginkgo
#

every startup AI is just a openAI wraapper
that's more or less my profile status lol

calm ginkgo
candid spire
#

As long as UK has good economy it would be matter of concern if things went wrong with UK.
If it becomes below top 10 or 20, most likely it would not be matter of concern if things went wrong with UK.

calm ginkgo
#

!e

print(type(list()), type(tuple()))
wise cargoBOT
candid spire
#

@paper wolf To code faster. think first act later!!

#

To go fast is to go well

#

Coding not the most difficult part for me

#

understanding problem and finding solution for such problem is second most difficult part of programming

#

coding is just 5 minute work

paper wolf
#

coding 8 hours a day

#

:D

#

8 hour +

candid spire
paper wolf
#

8 hour +

#

daily

candid spire
#

How can you type 8 hours a day straight

paper wolf
#

no live :D

candid spire
#

It's not possible to type code for 8 hours in a day

paper wolf
#

i just did lol

candid spire
#

So you give yourself no time to think about problem and solution

#

you just code and code

paper wolf
#

programming is mentally exhausting

candid spire
#

I don't think so

paper wolf
#

coding is something my hand can do without looking

candid spire
#

So can I do

#

but difference is I think before and create multiple possible solution in my mind.
Then I code

paper wolf
#

thats how i can code 8 hour+ daily

candid spire
#

After that most difficult part for me is debugging

paper wolf
#

but solving a actuall problem on the code

candid spire
#

actually coding is 2 hours at most

paper wolf
#

about 10% of that

candid spire
#

I ggot it

#

Ig it is called brut force approach

paper wolf
#

im just blindly writting stuff checking what works

candid spire
#

No wonder you are mentally exhausted

paper wolf
#

but my brain is dead thinking 30 things at a time

candid spire
#

Can you solve problem without thinking about code in your mind?

#

If you can, you should be not coding over and over again for the same project.

paper wolf
#

all at same time

candid spire
#

@paper wolf This is my approach, both in learning and in practice:

  1. I have a book with me
  2. I use this book to understand problem and write possible solution, it has no code just some maths and random diagram
  3. After understanding all possible solution as much as I can within a mind, I code it takes 5 to 10 minute.
  4. Now If I face any problem with code, I do debug which is most difficult part of coding.
  5. So most of my time is in fixing debug instead of writing a code for solution of problem over and over again.
paper wolf
#

i do have a book

#

its even filled with scribbles from the first very code i wrote

candid spire
paper wolf
#

no i write english to explain how the code should work, sometime i write oython code

paper wolf
#

i even simulate the state of the code for each step

candid spire
#

I barely write any explanation

#

is is pure maths and visual

paper wolf
#

i suck at math on that time so i dont do math ._.

#

visual is not my thing, i suck on visuals

candid spire
#

It is good pratice

paper wolf
#

i know a bit of math now

candid spire
#

Best advice would be

paper wolf
#

theres no lol, im super new on programming world ill discover it sooner or later

#

but its def not now

candid spire
#

Take notes on your activity during code

#

understand root problem for your exhaustion

#

look for reason

#

find possible solution which you can do

#

and practice those solution which you think can help you..

paper wolf
#

bo-a-wo-a

candid spire
#

@paper wolf Do you have any particular specializaiton?

paper wolf
#

no...

candid spire
#

Now it made sense

paper wolf
#

i write code stuff that interest me at the time

candid spire
#

you must be doing so many stuff at the same time

paper wolf
#

yes

candid spire
#

like game dev, web dev, so on

paper wolf
#

8 to be exact

#

with around 8 problem each

candid spire
#

Choose one and invest most your time in it

paper wolf
candid spire
paper wolf
#

now im doing other project to learn a specific things

candid spire
paper wolf
#

hmmm it was my main project, the Creates

candid spire
#

To do application in cpp?

paper wolf
#

@crystal fox 9!!!

candid spire
#

So you like coding in cpp.

paper wolf
#

that includes more than 5 files

candid spire
#

Gotcha

paper wolf
#

it was my first large project for over 2.5+ years of my coding journey

candid spire
#

Damn

paper wolf
#

im slow idk 🥲

candid spire
#

So why don't you learn more about cpp and make use of those learning in related field

paper wolf
#

my brain is noT working

candid spire
#

@crystal fox Are you good?

#

Okay

candid spire
#

How many different language you use @paper wolf ?

paper wolf
#

2 mainly but i know 3

candid spire
#

Good to know

#

I use 3 language and one of them is main.

#

other lang are more like optional

#

I'm focusing my energy on one specialization or stack

#

instead of exploring multiple field, I'm exploring multiple thing related to same stack

paper wolf
candid spire
paper wolf
#

i mean yes for sure but, i cant even finish a simple logic gate simulator app how ill make a entire game ._.

#

i can probably make a pingpong...

candid spire
#

I did not know coding

paper wolf
#

*programming

candid spire
#

but somehow I was able to code in c# and make game in unity

paper wolf
#

yeah cus of unity

candid spire
#

in those time

paper wolf
#

its same for me when i created the first ever code i wrote

candid spire
paper wolf
#

its just a simple emulation of a custom CPU architecture

paper wolf
candid spire
#

how about API and backend in c++?

paper wolf
#

tell that to our goverment 🥲

candid spire
#

You can do that?

paper wolf
candid spire
paper wolf
#

ive always do that since on python

#

i suck at frontend

candid spire
#

but component make it easier

#

learn react and make use of existing component for UI

paper wolf
#

im a low level guy, i never search for frameworks or libraries, i write a altenative

#

like most of the thing youll see on my projects barely has imports

paper wolf
#

IOT?

candid spire
#

Internet of things

#

like robotics and so on

paper wolf
#

????

candid spire
paper wolf
#

anyways its alr time ill sleep now we have 7AM class tomorrow

candid spire
#

Bye

paper wolf
#

i dont even have embed hardware

autumn pumice
#

any sysinternals geniuses here?

pseudo helm
#

hello

#

what's up? guys

#

I created my first Full stack application. Don't froget to look once

#

Have a nice day 😊

#

I hope you liked it 😁

thin wasp
#

Hey how are you guys . Can't speak in voice call bcz my mic is suppressed

wise loom
umbral mauve
#

immigrants doesnt always have choice

#

most of them are forced to leave their country

whole bear
#

Is he the same guy as early?
I mean he was racist now he is tech enthusiastic

wise loom
#

Remember when Sam Altman said AI data centers in space? Turns out that’s bs.

#

When has Sam ever said anything worth any credence or worth the time spent listening? I can’t recall a single such instance

latent nimbus
wise loom
# autumn pumice why would u say that

knowing about sysinternals alone is evidence enough for me.
anyway, you should ask your actual question, I'm sure if anyone knows, they will answer.

odd hollow
#

@wind raptor hello i cant tallk

#

yet

#

@wind raptor excuse me bro whitch domain u use python on

mighty linden
#

hey!

wind raptor
wise cargoBOT
#
Voice verification

Can’t talk in voice chat? Check out #voice-verification to get access. The criteria for verifying are specified there.

mighty linden
#

not segfault were you named lele in the afternoon

odd hollow
#

anybody here learn about DE ?

#

data engineering

mighty linden
#

what's reliable chatbot that's free nowadays to code?

odd hollow
#

hhhhh

mighty linden
#

with vscode

lavish rover
#

if you're a student get copilot

#

it's got all the major models

odd hollow
#

do you know something about it ?

lavish rover
#

otherwise most of the models have free plans but very limited use

odd hollow
#

okay bro i do selflearning i start with python and sql and know

#

i dont know what to do next

mighty linden
#

doing anything on your own takes a lot of time these days

odd hollow
#

i am i in the right road ?

mighty linden
#

someone else was talking abt antigravity previously

#

some people at yale dont like using computer?

odd hollow
#

i know but with python i can hadle oop very well and in sql i can create databases and tables

mighty linden
#

ecommerce.... googleanalytics, keywords, ads, and all.... not code odoo

odd hollow
#

i did

#

would like to see one

#

u

mighty linden
#

how to deal with scammers on fiver

vocal basin
mighty linden
#

asking for email and links and all

vocal basin
#

very slow progress

mighty linden
#

they say ive paid can you proceed or are they real /?

candid spire
#

Hello my bios

#

How was days?

#

Damn

#

I hope so

#

How about you?

#

Are you healthy and fine?

#

All of the fellow member have cold?

#

I can hear your cold in your voice

#

I heard a sound of breathing in mucus from nose

#

Okay

candid spire
vocal basin
#

which question

candid spire
#

What are your perspective on me since I have been in the server and talking to you and fellow members?

#

what do you think what age I am and level or EQ and IQ on your mind suitable for me?

vocal basin
#

IQ is a useless number

#

doesn't really represent anything meaningful

candid spire
#

How about other parts of question.

#

I would like to know your perspective.

mighty linden
#

chris what have you been working on

vocal basin
#

@wind raptor turns everything into Windows NT

#

NTify

mighty linden
#

wow!

woeful blaze
#

How are you doing today mindful

mighty linden
#

cassidyn't what are you working on

#

i am having some

#

1yr+

vocal basin
#

MERN

#

I still haven't used MongoDB

mighty linden
#

MongoDB is collections based db

vocal basin
#

I understand some theoretical basis of it

mighty linden
#

pipelines are tricky there

#

i used it once

vocal basin
mighty linden
#

i do a bit of everything is mytype of dev

#

depends on the risk taking capacity of the interviewer

vocal basin
#

interviewers will generally prefer if the candidate appears specialised for the specific things they ask for

#

based on the assumption the candidate spent more time on those things if they didn't do anything else

mighty linden
#

they make you sign contract upfront

#

all my friends do unpaid intern here

vocal basin
#

XML HTTP Request

mighty linden
#

JavaScript API

vocal basin
#

what fetch replaced

mighty linden
#

ajax

#

like these

#

dont learn language learn sys design and like concept first

vocal basin
#

learn both, languages are heavily involved in representing those concepts

mighty linden
#

then the backend and lang

vocal basin
#

@whole bear do you know how to implement a compressed trie?

mighty linden
#

what ? ?

#

can you say that again i didnt hear you

vocal basin
#

@wind raptor are you still having mic issues?

mighty linden
#

which one ? which website

#

this one ?

vocal basin
mighty linden
#

let's sync it here? then like these that are doing

vocal basin
#

making your own company means paying tax twice: sales and salary

mighty linden
whole bear
#

Thank you for your time!

#

It was fun having a conversation.

rugged shadow
#

ok

whole bear
#

Bye

whole bear
mighty linden
whole bear
#

People like me have a low chance of being hired

livid niche
#

yo

whole bear
#

Equity is an asset that has value only if it has demand.
If the company is private and small with small revenue and profit, equity has no value!

mighty linden
whole bear
#

Not every

#

Simple law of capitalism:
There will be a depressed class

livid niche
#

ive written some functions in bash

vocal basin
#

FastAPI is a DI framework for starlette

livid niche
#

a hypervizor? or did i mishear @pseudo helm

#

@pseudo helm you mean tech support doesnt support distros that arent enterprise?

#

@echo bison ive been messing around with bash

#!/bin/bash

declare -a incnumbers

numinc(){
    num="$1"
    inc="$2"
    ceil="$3"
    incnumbers+=($num)
    while [ $num -lt $ceil ]
    do
        numinc=$(( $num + $inc ))
        num=$numinc
        if [ $num -le $ceil ]; then
            incnumbers+=($num)
        else
            continue
        fi
    done
}

numincout(){
    for items in ${incnumbers[@]}
    do
        printf "$items\n"
        unset incnumbers
    done
}
#

@echo bison declare -a makes an array

#

unset means it flushes the array

#

because if i call numinc and then print its array and then call numinc again and print it, that array is gonna just expand

vocal basin
livid niche
#
#!/bin/bash
source ./test.sh

numinc 0 3 31 && numincout
pseudo helm
#

Zsh

livid niche
#

ive heard dash is nice but i have been hesitant to use it

pseudo helm
#

Terminal

vocal basin
#

#!/usr/bin/env bash

livid niche
#

the if statement is important to prevent it from adding beyond the ceiling to the array

#

!e

pseudo helm
vocal basin
pseudo helm
#

Anybody used it ?

vocal basin
#

share.google looks suspicious

pseudo helm
livid niche
#

!e

#!/bin/bash

declare -a incnumbers

numinc(){
    num="$1"
    inc="$2"
    ceil="$3"
    incnumbers+=($num)
    while [ $num -lt $ceil ]
    do
        numinc=$(( $num + $inc ))
        num=$numinc
        incnumbers+=($num)
    done
}

numincout(){
    for items in ${incnumbers[@]}
    do
        printf "$items\n"
        unset incnumbers
    done
}

numinc 0 3 31 && numincout
wise cargoBOT
livid niche
#

oh its python only

#

lol

vocal basin
#

so it's not really even shortened

livid niche
vocal basin
livid niche
#

@pseudo helm its a hyrax

vocal basin
#

it got almost a whole line without a syntax error

livid niche
#

related to elephant

wind raptor
#
numinc(){
    num="$1"
    inc="$2"
    ceil="$3"
    while [ $num -lt $ceil ]
    do
        numinc=$(( $num + $inc ))
        incnumbers+=($num)
        num=$numinc
    done
}
vocal basin
livid niche
#

@echo bison function(){...} is a function syntax

wind raptor
#

I'm just simplifying what was there a bit

vocal basin
livid niche
livid niche
vocal basin
#

why is this not a word in this dictionary

#

and just `taxon' is

wind raptor
#

I was just pointing out one thing without refactoring the rest

echo bison
wind raptor
#

my bad

vocal basin
pseudo helm
#

Are you hating me for no reason?

vocal basin
#

ah, because taxa

vocal basin
pseudo helm
#

Oh

#

My bad

#

British English is little bit different

livid niche
vocal basin
#

okay so taxons is apparently not entirely a word

pseudo helm
#

Pardon me 🙏

vocal basin
wind raptor
#

This also won't add the number if it starts above your ceil

livid niche
#

oh i can get away with using variables inside of $(()) without needing to put $ next to the variable name?

wind raptor
#

I can't say I'm good with bash, but I am decent with logic

#

haha

livid niche
#

nice, i didnt know this

#

im so used to bash requiring $

wind raptor
#

It was unintended as I wrote it, but intended when I pushed enter 😉

livid niche
#

for variables

wind raptor
#

Could be

livid niche
#

woah

#

why are messages getting thanos snapped

primal shadow
#

Thanos gonna Thanos

livid niche
#

dont dissappear oh great bash wizard

primal shadow
livid niche
#

NOOOOOO

vocal basin
#

accidentally overhyped

vocal basin
#

when the company that didn't bother with developing software too much

whole bear
#

Hello 👋

lavish gazelle
whole bear
#

I was curious to ask, is it permissible to ask for anything related job?

lavish gazelle
#

@wind raptor

vocal basin
#

I'm looking at the server not dying of heat (for now)

#

long time ago, before the proper cooler was installed, it did sometimes rise to 90 degrees C

#

@wind raptor what a scrummy remark

wind raptor
vocal basin
vocal basin
#

!paste

wise cargoBOT
#
Pasting large amounts of code

If your code is too long to fit in a codeblock in Discord, you can paste your code here:
https://paste.pythondiscord.com/

After pasting your code, save it by clicking the Paste! button in the bottom left, or by pressing CTRL + S. After doing that, you will be navigated to the new paste's page. Copy the URL and post it here so others can see it.

vocal basin
heavy zenith
vocal basin
#

you can derive Default if you want a quick way to implement filling all fields with zeroes, however that doesn't work in const contexts

#

add and sub should probably be impl Add and impl Sub instead

#

so that + and - work

#

and scale would be Mul<f64>

#

doing normalisation for force calculation sounds a bit off

#

.norm() gets called twice

#

and in one of the cases it then undoes sqrt

inland cosmos
#

I will just sit with you for a bit, if you don't mind

vocal basin
wise cargoBOT
#

file 1 line 55

if distance == 0.0 { return Vec3::zero(); }```
vocal basin
wise cargoBOT
#

file 1 line 52

// if the distance == 0 return an empty vector```
vocal basin
#

empty vector is vec![], a collection

#

norm can be split into two methods, with one of them returning it squared

#

@heavy zenith JS

#

distance*distance

#

this undoes sqrt

#

sqrt is expensive to calculate

lavish gazelle
#
number = 100
sqrt_number = number << 1
#

@heavy zenith

vocal basin
#

the classics

float Q_rsqrt( float number )
{
    long i;
    float x2, y;
    const float threehalfs = 1.5F;

    x2 = number * 0.5F;
    y  = number;
    i  = * ( long * ) &y;                       // evil floating point bit level hacking
    i  = 0x5f3759df - ( i >> 1 );               // what the fuck?
    y  = * ( float * ) &i;
    y  = y * ( threehalfs - ( x2 * y * y ) );   // 1st iteration
//    y  = y * ( threehalfs - ( x2 * y * y ) );   // 2nd iteration, this can be removed

    return y;
}
#

@heavy zenith for this one it's fine

heavy zenith
#

i = * ( long * ) &y;

lavish gazelle
vocal basin
vocal basin
#

in C, allowed

#

yes

heavy zenith
#

ask

#

aks

wind raptor
#

Gotta make some dinner. Cheers

tepid edge
#

On JAL you get one hour of free wifi for each email address you can name

#

Pretty sweet deal

vocal basin
#

@heavy zenith I don't think you'd lose much because of precision, but, from what I know, modelling it is excessively hard for different reasons

#

FFT and operations adjacent to it should be fine with f64

#

(iirc that one is needed for doing the "compare everything with everything" kind of operations)

#

there are existing implementations

#

Rust itself doesn't provide types for it

somber heath
#

@warped tusk 👋

#

@astral wigeon 👋

#

@tropic jay 👋

vocal basin
#

databases belong in containers

#

@crystal fox containers are not VMs; if code runs in a container, then it runs on bare metal

#

@crystal fox installation and maintenance of installing outside the container is waaaaaaaaaaaay more complicated

#

BSD Jails, one of earlier containerisation techniques, have been around since 2000

#

@patent chasm especially with Alpine for the container: directly binds to syscalls instead of going through glibc

somber heath
#

@last mantle 👋

last mantle
#

Hi

#

I'm really new to coding just started learning by myself around 1 month ago.

#

Currently I work on a little side project about student enrollemnt system haha I confuse about save and load with json right now haha

#

yeah yeah I have to learn a bit about json library stuck here for few days now haha

#

yep I do clean code seperate file and all those stuff

vocal basin
#

✅ clean code
❌ Clean Code

#

with FastAPI and things alike (e.g. axum) there's at least somewhat less of explicit parse/unparse calls

#

(for JSONing/unJSONing)

#

there is a thing that combines Pydantic and SQLAlchemy

last mantle
#

time to look into SQL it seem

patent chasm
#

look into graph vector database

#

will make your life easier

last mantle
#

I will take note of that graph vector got it

patent chasm
vocal basin
#

using graphs here sounds like a bit of overengineering

#

need to have enough non-trivial connectivity to justify

last mantle
#

after this project and more of basic fundamental stuff also want to create mini 2d game in Python from scratch with its own engine may be try Pygame or something like that. It might be good project for learning I think.

patent chasm
#

and then append stuff to each student node

last mantle
#

Wow, printer mafia exists? sound so bad.

inland gorge
#

im rookie but i cant wrap my head around why solutions in python are just so slower than in c++ or even c or rust . python is easy so i like doing it for CP but idk

#

@somber heath

#

@somber heath

vocal basin
#

please don't abbreviate `competitive programming' like that

somber heath
#

I didn't see it until just now.

patent chasm
somber heath
#

@inland gorge I'm ready to talk about that now if you like.

#

@whole bear 👋

#

@rugged gyro 👋

inland gorge
#

!!

#

@somber heath im here

#

hello

#

that makes sense would u say python is just a really well done domain specific language kindof thing ?

#

yea ive had opprtunities to. do questions in like 1 or 2 lines in python against like 10 lines in C

vocal basin
#

do remember: GIL-free Python is slower for single-threaded workloads

#

so not always getting faster

#

JIT is happening

#

that might be a more universal improvement

#

match got way faster compared to what it used to be

#

(match used to be strictly slower than equivalent if structures)

patent chasm
#

the true use of AI

scarlet dust
#

raagh

livid niche
#

Sadly no SPI pins 😭

#

Meaning I can't interface with the SPI pins on the CPU

#

@somber heath how are you have you seen any birds today

somber heath
#

A few.

vocal basin
# scarlet dust

for whatever reason, I had this issue exclusively with Chrome

#

(with Firefox running into "Checking Route" instead, usually)

scarlet dust
#

odd

somber heath
#

Mt. Buggery.

vestal merlin
#

@undone frost my internet is fucked lol

somber heath
#

It would be Japan.

scarlet dust
patent chasm
#

<a href="http://www.example.com" target="_parent">Open Link in Parent Window</a>

scarlet dust
somber heath
#

@mental lion 👋

jaunty socket
craggy vale
#

this is playlist

lavish rover
#

pita

craggy vale
timid quartz
craggy vale
somber heath
#

@little valve 👋

little valve
somber heath
#

@solar smelt 👋

solar smelt
#

yoo @somber heath

#

hello @wind raptor

woeful blaze
jaunty brook
craggy vale
#

it's a debian based linux distro

craggy vale
#

@wind raptor look the OS talking the ram

#

the pure

#

OS ram uses

craggy vale
brave fossil
#

hi

#

dude ur mic is on

#

what just happend

#

?

#

@candid spire sry i dont have a mic :(

#

WeirdBoi thats correct :)

#

anyone wanna see one of my projects?

#

ill stream it in Live-Coding vc

#

why cant i stream??

#

idk

#

I mean it says LIVE coding

#

wait

#

let me try to send a video

#

here's a screenshot, my program is a autoclicker. heres the test result

#

its 1096 CPS

#
import threading
import time
from pynput.mouse import Button, Controller, Listener as MouseListener

mouse = Controller()
clicking = False
running = True

def click_loop():
    while running:
        if clicking:
            mouse.click(Button.left)
            time.sleep(0.001)  # Adjust click speed here
        else:
            time.sleep(0.1)

def on_click(x, y, button, pressed):
    global clicking, running
    if pressed:
        if button == Button.x1:
            clicking = True
            print("Autoclicker started.")
        elif button == Button.x2:
            clicking = False
            print("Autoclicker stopped.")

# Start the click loop in a separate thread
thread = threading.Thread(target=click_loop)
thread.start()

# Listen for mouse button events
with MouseListener(on_click=on_click) as listener:
    listener.join()
#

this is the code

#

I'll try

#

I can change the speed

woeful blaze
craggy vale
primal shadow
#

🌊

#

Coding challenges

#

mroe like leetcode

#

2 problems a day

dry jasper
primal shadow
#

interwoven with a story

dry jasper
#

@whole bear

primal shadow
#

SLACKERS!

dry jasper
#

ASCII ART

amber raptor
#

I failed problem 2

#

And brute forced problem 1

cloud lotus
#

@dry jasper are there some websites that I can practice my basic python knowledge on?

cloud lotus
#

okay Ill check it out

#

okay thank you

dry jasper
cloud lotus
#

okay

#

alright bet thank you

mighty linden
#

What are we talking about?

candid spire
#

Hi

mighty linden
candid spire
mighty linden
#

Where

mighty linden
#

I have no idea what are we talking about

candid spire
#

I have no idea

#

I lefft

dry jasper
#

@patent jungle

frozen zephyr
#

Guys

#

You think AWS certification worth it? I mean to data field

#

Yeah

#

Because I'm in the same sittuation of the sofus

#

Oh sorry

#

Thouzand was the one who are a begginer in data :

#

?

#

Ahh ok

#

My bad

#

Anyone here work with data science?

#

Could you repeat the name, please?

copper narwhal
#

Hi guys, I am new to this space

primal shadow
#

hello

#

welcome

copper narwhal
#

Can I get a chance to talk?

primal shadow
#

pycharm

#

ah, not python

frozen zephyr
#

Nice tips, Animmo

candid spire
#

Hello

#

I'm sorry for my earlier behaviour

primal shadow
#

Another lovely day

copper narwhal
#

I don't qualify to use voice chat lol.
I am a GIS & Urban Planning student in my final smester but unfortunately I failed for final GIS class because the course was related to Python, especially Arcpy and Numpy.
Just want to ask a question - is it realistic to learn Python in 1 month?

primal shadow
#

Not ata the moment

#

was thinking of loading it up

#

it is lunch time after all

#

Satisfactory

#

the game I was playibng

#

yes

candid spire
#

I guess he is playing a game which everyone plays

primal shadow
#

Oh, rimworld?

candid spire
#

life

primal shadow
#

I've been working on Satisfactory as of late

#

RImworld on break for now

frozen zephyr
#

life it's a very difficult game

#

🙂

primal shadow
#

Rimworld is the colony sim, Satisfactory is a 3D factorio

#

but worse

#

so much worse

#

Rimworld is one of the best games ever

#

as is Factorio

#

Rimworld is a colony sim

#

A story generator

candid spire
#

Thouzand

#

were are you from?

#

Those who are born in US are lucky af

#

they can buy gun

#

I can play real life pubg

whole bear
candid spire
#

Okay?

#

Nope

#

I would like to play real life squid game

dry jasper
#

takeshi's castle

whole bear
candid spire
#

would be enough

whole bear
#

is it a gun?

whole bear
#

💀

#

nice

candid spire
#

after bribe it is second most critical thing for cops

#

You are from netherland bro

#

cops over there are chill

primal shadow
candid spire
#

US cops are interesting, it is army disguised as cops

whole bear
#

bro has analyzed whole world police attributes ig

candid spire
primal shadow
#

Not everyone

candid spire
#

!8 +?

primal shadow
#

All sorts of reasons to take em away

#

Not really a right

#

in my book

#

if it can be taken

#

More like permission

candid spire
#

I think police should have bazuka

primal shadow
#

that can be revoked

candid spire
#

normal gun ain't enough for them

primal shadow
#

I think I should be able to have an atomic bomb

#

self defense, ya know?

#

SHALL NOT BE INFRINGED!

candid spire
#

why atomic bomb?

primal shadow
#

Why not?

#

It's the biggest boom

candid spire
#

hydrogen would be better

#

vapourized to death

primal shadow
#

Technically to have an H bomb you gotta have an A Bomb rihgt/

candid spire
#

Yep

primal shadow
#

So maybe the Abomb I wanted is the one contained within the H bomb

#

idk

candid spire
#

but atomic bomb is slow death

primal shadow
#

either one should suffice for self defense

candid spire
#

hydrogen bomb is instant vapourized death

primal shadow
#

clip so good it's worth watching the whole thing

candid spire
#

American gun law are inspired from switzerland

primal shadow
#

See how well bigger weapons self defend?

#

Just need a mail truck to hold that missile from the USSR

candid spire
#

Do you know worst cops in world ain't US cops it's North Korean cops

primal shadow
#

IDK about that

#

I feel like in NK they're corrupt from the top down, in the US it's bottom up

candid spire
#

up ain't corrupt?

primal shadow
#

It is

#

Through and through at this point

candid spire
#

Hmm

#

who cares

#

life is fragile

primal shadow
#

No point fighting for last place, I agree

whole bear
#

@dry jasper he's not in vc

#

yeah, classic one

#

I was checking cross platform, includes mobile app and I found this one.

#

it's in dart

#

Google pay in Flutter ig 🤨

#

I see, so basically scalability is the problem!?

#

I thought of react native 😭

quasi breach
#

Hey guys

whole bear
#

@whole bear it's good

#

you haven't heard me yet

#

🙂

#

my english 😢

#

yes, exactly we can communicate

#

😎 Yes

whole bear
#

Gtg

livid niche
#

;e

print(random())
wise cargoBOT
#
Missing required argument

code

livid niche
#

!e

import random
n = None
print(random(n))
#

!e

import random
n = None
print(random(n))
wise cargoBOT
# livid niche !e ```py import random n = None print(random(n)) ```

:x: Your 3.14 eval job has completed with return code 1.

001 | Traceback (most recent call last):
002 |   File "/home/main.py", line 3, in <module>
003 |     print(random(n))
004 |           ~~~~~~^^^
005 | TypeError: 'module' object is not callable. Did you mean: 'random.random(...)'?
livid niche
#

!e

import random
print(random.randrange(1, 4))
wise cargoBOT
livid niche
#

@wind raptor trying to make the random range function slightly better

#

@wind raptor i noticed it has preference to 1's when you do (1,4)

vague bison
#

hi

#

how are you guys

#

just saying, I don't really want to unmute myself

livid niche
#

@wind raptor maybe more things but it gets better with bigger parameters

vague bison
#

i just wanna listen if thats OK?

livid niche
#

@wind raptor with bigger parameters like (40,100) it feels like a better random

vague bison
#

So, whatcha guys workin on?

livid niche
#

@wind raptor is there a way to use parenthesis like how you do in regular math using python without it being considered a module?

#

!e

import math
a = 10
b = 10
print(10(a+b))
wise cargoBOT
# livid niche !e ```py import math a = 10 b = 10 print(10(a+b)) ```

:x: Your 3.14 eval job has completed with return code 1.

001 | /home/main.py:4: SyntaxWarning: 'int' object is not callable; perhaps you missed a comma?
002 |   print(10(a+b))
003 | Traceback (most recent call last):
004 |   File "/home/main.py", line 4, in <module>
005 |     print(10(a+b))
006 |           ~~^^^^^
007 | TypeError: 'int' object is not callable
vague bison
#

I'm curious...

livid niche
#

i wanna express 10(a+b)

#

without it being considered module

vague bison
#

hey Chris

livid niche
#

@wind raptor ik its just using parenthesis looks more pleasing, i was curious if there was a workaround

vague bison
#

whatcha guys workin on

#

oh cool.

livid niche
#

@wind raptor is sympy the spelling

vague bison
#

so bassically a calculator package in python?

#

kinda?

#

oh cool.

#

yeah. i like to use thonny python, so you know how you can go to tools > manage packages?

wind raptor
#

!e

import random
from collections import Counter

times = 10000
data = [random.randrange(1, 4) for _ in range(times)]
counter = Counter(data)
print(counter)
wise cargoBOT
livid niche
#

@wind raptor i have a work around for random sucking for small inputs that would theoretically work, i just need to install pip

vague bison
#

Hey Chris. how much do you know about pybricks or thonny python?

#

idk

#

it uses micropython

#

ye

#

if i need help with something, where do i go, Chris?

livid niche
#

@wind raptor is there an alternative of len() for ints

#

@wind raptor i need the length for doing 10^n

vague bison
#

@wind raptor if i need help with something, where do i go?

#

ye

wind raptor
livid niche
vague bison
#

I was asking you because i was thinking you may be a mod or something.

livid niche
#

and follow guidelines

#

@wind raptor whats the symbol python uses for exponents, i tried ^ and that seems to be something else

wind raptor
#

**

inland cosmos
#

Hi

#

How are you

#

I'm good

livid niche
#

i found out a workaround for len() not working on ints

int(len(str(var)))

vague bison
#

Hey, thanks Chris. Imma gonna go ahead and post my thing... whatever it's called. (I'm still new here, so I'm still kinda getting used to some of the stuff.)

livid niche
vague bison
#

wait, say that again please?

#

oh, ok.

#

cool

wind raptor
#

!paste

wise cargoBOT
#
Pasting large amounts of code

If your code is too long to fit in a codeblock in Discord, you can paste your code here:
https://paste.pythondiscord.com/

After pasting your code, save it by clicking the Paste! button in the bottom left, or by pressing CTRL + S. After doing that, you will be navigated to the new paste's page. Copy the URL and post it here so others can see it.

vague bison
#

yeah ok

bleak sapphire
wise cargoBOT
vague bison
#

can you possibly help me with a voice chat in python? I can explain how i want it to work.

#

if you need me too

#

i can explain in chat

#

ye

livid niche
#

well on the bright side its presumably a useful module

inland cosmos
#

Are you here everyday? @wind raptor

#

Currently trying to understand OOP. How long
did it take you to understand it?

#

Yeah inheritance and all this stuff scares me

vague bison
#

here ya go, Chris:

#

so, I want two programs; a client program and a server program. the server program would go onto my 2018 raspberry pi 4 model B and the client program would be used on any computer. (though i kinda want the client to be an app since that would be easier. just boot the app and the're ya go.) When the client starts running, it connects to my raspberry pi via cloudflare tunneling. (I'm thinking about using try.cloudflare.com for temporary tunneling.) So, after it connects, it'll somehow broadcast your voice to any other clients connected. another thing too, I'm using raspbian OS lite. (64 bit i think?? I can't remember...)

wind raptor
#

Counter({'1\n': 345, '3\n': 336, '2\n': 319})

After running 1000 subprocesses with only a single print @livid niche

livid niche
livid niche
inland cosmos
#

Just created a class and wrote some methods. Simple stuff really. Just understood the concept of object.
Also been using modules from pypi because they use objects as well.

#

Function inside class

livid niche
inland cosmos
#

To create different objects that have different data ig

#

And run functions on them

#

Can't explain it lol

#

Yeah

#

Didn't understand it yet

#

Also maybe you know what setters and getters are for

#

Because i can't imagine real world use

#

Yeah it just conventional to use _var names

timid quartz
#

@wind raptorcan u join call and let me ss

inland cosmos
#

Appreciate answers. It means a lot. Bye

vague bison
#

Hey, Chris