#ot2-the-original-pubsta

652 messages · Page 56 of 1

wide totem
#

Why not?

median blade
#

just askin

#

cuz there already is one

wide totem
#

It's a fork of kyb3r's bot

median blade
#

present

wide totem
#

Which is the bot of this server

median blade
#

o

wide totem
#

And at least 9k other servers

#

Basically used in a lot of servers

#

If you see a modmail chances are pretty good it's this bot

#

Unfornately, it does have some quirks and flaws.

#

I'm trying to fix that and make it easier for all to use while still being insanely customizable.

#

But perhaps you want to deploy multiple bots all with the same custom settings.

#

So there's a way to configure settings through a .toml

cursive bluff
#

I have started to study Data Science from online courses .Currently I am planning to buy a laptop which will help me in studying Data Science and also in the long run. Please recommend me a suitable laptop

blissful coral
#

cloud is a bit expensive tho, but as long as you have a job - shouldn't be too much of an issue

median blade
#

its supposedly good for ML

#

tho idk how it will compare to an AMD

hazy laurel
#

I'd probably recommend a gaming laptop at that point

#

but like a good one...

blissful coral
daring jay
#

Why does it matter if it's a Macbook or anything else? (this is coming from someone with no hardware knowledge)

median blade
#

M1 is not that good of a CPU

blissful coral
#

M1 is much better for AI > CPU because of neural engine

hazy laurel
#

because Apple is notorious for not being worth your money

blissful coral
median blade
#

wat

#

i did not ping

daring jay
blissful coral
#

Apple might be "notorious" but unless anyone can give me a spec sheet and 10 page essay on why M1 is bad for ML, those arguemnts are useless

median blade
#

what resources does ML take?

odd sphinx
#

well for starters it takes memory

median blade
#

mhm

#

and?

blissful coral
#

Neural Engine and shared memory are +++ for large models

odd sphinx
#

and cpu

daring jay
#

Okay, say Mac is good. Is everything else bad?

odd sphinx
#

ikr

hazy laurel
blissful coral
odd sphinx
#

dang

#

mac vs everyone else

#

epic

hazy laurel
#

The debate is not whether or not it's "good" it's a comparison of all options and how much you've gotta pay for them and what you get in return

blissful coral
#

M1 helps much more than a normal CPU. granted, software support is kinda slow but it's a long term plan

#

the debate is not mac vs. anything else

hazy laurel
#

I refuse to believe any Apple device is ever worth the price

jovial island
#

alright

blissful coral
#

it's the best recommendation for DS/AI, which is M1, which is Mac Mini or Air or Pro

#

iMac is good too

hazy laurel
#

Where does this come from, though?

blissful coral
# hazy laurel Where does this come from, though?

for large models, memory becomes a huge bottleneck. shared memory is faster, its kinda cheaper too (seeing Apple tax) and Neural Engine can be fully optimized to take full advantage which is something AMD lacks. (who talks about f-ing intel lol)

#

for serious DL, it's cloud + TPU

median blade
#

but what about GPU's 😏

blissful coral
#

but for normals, M1 does fine

#

CUDA is proprietary, so is Apple @median blade

median blade
#

yeah at the price , you can get a more powerful machine lol

hazy laurel
#

A single processor is not worth a whole laptop ngl

median blade
#

better off not buying apple

blissful coral
#

probably not, but for DS it is

daring jay
#

Just get a good OS, beef it up with a nice CPU if you really need it, and be happy

median blade
#

it doesnt work that way

hazy laurel
#

I doubt it's worth it, truthfully

blissful coral
daring jay
median blade
#

ML is heavy

#

hardware intensive

blissful coral
#

I mean, why are we even arguing if most of you don't do ML?

median blade
#

if you for some reason want only a CPU in your laptop - it should be light etc, an Apple device is a great option

odd sphinx
#

yes

median blade
#

cuz one person asked

blissful coral
median blade
#

wat

hazy laurel
#

I imagine you can put the money you save from buying a whole macbook into cloud, honestly

median blade
#

mm true

blissful coral
hazy laurel
#

If you're just experimenting, then you don't need every ounce of performance

median blade
#

you waste a lot of $ on Apple too lol

blissful coral
#

speaking from expereince who blew 600$

blissful coral
median blade
#

no

blissful coral
#

I can use it a long time, while in cloud only for a few weeks

hazy laurel
#

Apple products are essentially built specifically not to last

median blade
#

ah that way

hazy laurel
#

and this has been proven time and time again

odd sphinx
#

damn

hot pulsar
#

and its ~free~

blissful coral
#

see, either you can get the "APplE bAd"route, or you could look at the hardware

odd sphinx
#

and go the apple bad route

#

either way

median blade
#

and i say its overpriced for the hardware

blissful coral
#

either way, depends on the budget

hazy laurel
#

The mentioning of Apple immediately puts me off

median blade
#

same

odd sphinx
#

oof

blissful coral
#

then don't talk about it 🤷

median blade
#

k

odd sphinx
#

k

hazy laurel
#

I don't think I prefer having someone recommend a macbook

median blade
#

i would only for design etc

blissful coral
#

your choice - MB's are pretty standard in DL now since M1 got Neural Engine

median blade
#

adobe software

blissful coral
#

it's basically a huge edge over AMD

median blade
blissful coral
median blade
#

AMD with GPU will kill apple ig

hazy laurel
#

but if you really need that much performance, I don't think getting that from a laptop is a good idea

odd sphinx
#

agree

hazy laurel
#

especially an Apple one

blissful coral
median blade
#

yeah so , at the same price, you can get an AMD + GPU lol

hazy laurel
#

so then why does it matter ;-;

odd sphinx
#

ikr

hazy laurel
#

You have to assume that person is going to be daily driving that laptop... and I refuse to believe a mac is their best option

odd sphinx
#

why does anything mater

median blade
#

i can fkin get a 4800H CPU + 1660Ti for the price of a macbook lmao

#
  • 16GB
#

RAM

blissful coral
#

because with an AMD + GPU comb, you can't train big models you would actually use IRL. but pre-trained models can be fine-tuned on Neural engine and shared memory can help to use the large flavours of some models too

odd sphinx
#

ram

hazy laurel
#

The only acceptable reason is that someone has the money and just likes the UI

#

No matter how much that mentality annoys me

median blade
hazy laurel
#

I still think the money can be better spent

blissful coral
#

uh-huh. that's why M1 is pretty great for data scientists. prob widespread adoption may take place if they make it more cheaper at M3/M4 and more focused in Neural Engine

#

knowing apple, they can prob afford a new lineup with a new chip

hazy laurel
#

God, I'd hate to be put in that position

median blade
#

M2 is coming very soon

#

with 40 cores i guess

blissful coral
hazy laurel
#

if I have to seriously consider getting an Apple product, something is wrong

blissful coral
#

Only for AI/DS/Artistic work = Mac

hazy laurel
#

I just don't think any hardware gains are worth it when it comes to Apple

#

because everything else just doesn't make it worth it for me

blissful coral
hazy laurel
#

Yes and they're weird

odd sphinx
#

lol

#

final cut bro!!

median blade
#

no i agree with ruler with this

#

creative art = apple

#

no other way

hazy laurel
#

But why

odd sphinx
#

they do use apple

hazy laurel
#

I never understand

median blade
#

Adobe suite

#

final cut pro

odd sphinx
#

that true

median blade
#

all works very well in mac

blissful coral
median blade
#

and Mac displays are sick

odd sphinx
#

bruh

#

u sound like an ad

#

but mac displays are good

blissful coral
hazy laurel
#

I don't know, I know too much... My decisions are always based completely on efficiency

odd sphinx
#

pro duplsay xdr

median blade
blissful coral
#

mind = blown

hazy laurel
#

and I find Apple absolutely horrible for anything efficient

odd sphinx
#

bruh

hazy laurel
#

Everything is always completely preference

odd sphinx
#

only artists need that kind of resolution

median blade
#

its easy to see that mac's are aimed at creative profssionals

odd sphinx
#

max i would get on a laptop is 4k

#

and only if it can be 144hz

blissful coral
#

exactly

hazy laurel
#

I mean what's stopping them from using Windows or something?

odd sphinx
#

i think its the ecosystem

#

they most likely have an iphone

median blade
#

ye

#

eh

#

nono

blissful coral
#

artists love that sort of thing - wider colors, more art emphasis, integrated eco where everything simply works

odd sphinx
#

yes

median blade
#

the software hardware integration is very nice with Mac's

odd sphinx
#

yes

blissful coral
#

they don't want to mess about nerdy things like patches and code. they just want their shit to work

#

makes sense from their perspective

odd sphinx
#

yes

#

agree

hazy laurel
#

I kind of feel like 99% of them don't even think about patches

#

if that's even really a thing

odd sphinx
#

because thats not their job

#

they want things to work

blissful coral
#

I feel like 99% don't even know about technical things, and they shouldn't really

odd sphinx
#

they dont have to

blissful coral
hazy laurel
#

so how does that justify "their point" if they don't even know it's a point?

median blade
#

wat

odd sphinx
#

?

blissful coral
#

wdym

daring jay
#

People want what works for them

hazy laurel
#

I mean to say

odd sphinx
#

ye

daring jay
#

Mac works for artists(and other people) who don't want to mess with technical stuff

hazy laurel
#

How do they know Apple fixes their problems if they didn't even know they had problems to begin with

hazy laurel
median blade
#

they did have problems

daring jay
median blade
#

Windows laptops dont come with high refresh rates, icky integration etc

daring jay
#

But some people just might prefer mac

hazy laurel
#

But you mention mac specifically

median blade
#

yes mac

#

i told you why :/

blissful coral
daring jay
odd sphinx
#

lol

median blade
#

for example, Adobe loves to crash in my PC

hazy laurel
#

What an annoying situation

odd sphinx
#

ye

timber mango
#

For me, even Microsoft office crashes

median blade
#

lmao

hazy laurel
#

Oh well. I'll forever abstain from both macOS and Windows (as much as I really can)

blissful coral
#

I mean, I tried to do music production in windows and I couldn't even get the fukin installer to run

median blade
#

eh

odd sphinx
#

dang

median blade
#

its not that bad

hazy laurel
#

Apple just really has a monopoly on their own software

median blade
#

its just not efficient

hazy laurel
#

everything they have only works on what they have

blissful coral
#

perhaps. But with Mac, you know most Apple software works out of the box

hazy laurel
#

all they do is raise the price and make their products intentionally bad

odd sphinx
#

but enough to still work

#

very well

#

with other apple devices

blissful coral
odd sphinx
#

yes

blissful coral
#

they don't want to fix stuff they don't understand

hazy laurel
#

I've already said that

blissful coral
#

they would pay more just to get everything to work

hazy laurel
#

Which is just an annoying mentality, honestly

#

because now all the support goes over to Apple

#

and so those who refuse to use Mac (cough) are stuck with the shorter end of the stick

#

and the monopoly continues

#

because there's no reason this software can't work fine on another OS

median blade
#

yes and no one can do anything about it 👍

blissful coral
#

same way we don't know about what chemicals we get when we drink coke, but chemists would consider it heresy that you drink somthing which has x chemical which would cause cancer.

I don't really care i would get cancer. I just want to enjoy my coke

median blade
#

wat

hazy laurel
#

I mean I'd rather live with a "worse" experience than support a company like that

timber mango
#

Yeah shooting the gun for the love of its sound

hazy laurel
#

I mean I'd save more time fixing whatever issues I encounter rather than having to work more hours to make up for the price

median blade
#

issues you cant fix

#

...

hazy laurel
#

Like what?

odd sphinx
#

like me

#

:"(

somber belfry
#

hey, that's okay :O

#

no one wants to use you anyway

#

❤️

median blade
odd sphinx
hazy laurel
median blade
#

final cut pro

hazy laurel
#

and I don't understand the "high res screen" argument

odd sphinx
#

i think u can get high res screens

#

maybe they might not be colour accurate

median blade
#

im talking about laptops here btw

odd sphinx
#

bruh

hazy laurel
median blade
#

and for the price, apple is the best

hazy laurel
#

:|

somber belfry
median blade
#

context...

odd sphinx
#

lol

hazy laurel
#

Idk man. I have a hard time believing Apple is ever the "best"

median blade
somber belfry
median blade
#

afaik yes

somber belfry
hazy laurel
#

I'd still prefer Manjaro over macOS ngl

somber belfry
median blade
round moss
#

yeah, Final Cut pro is a very solid piece of software

hazy laurel
#

as compared to what, though?

odd sphinx
#

i assume it crashes less than premiere

round moss
#

Premiere

median blade
#

lol yes

round moss
#

companies don't use Apple for the lulz, they use apple because it is the most profitable

odd sphinx
#

well ive never really done any 6hr editing job so my premieres never crashed

median blade
#

yup

somber belfry
timber mango
#

1st rule for me as a programmer is whatever i use should be a free software. I haven’t spent a single penny for online software

round moss
#

yeah, that is a worthy priority

#

gentoo even lets you set a limit which prevents non-free software on your PC

odd sphinx
#

damn

round moss
#

and its the default

odd sphinx
#

lmao

#

thats funny

#

how does it recognize paid software

hazy laurel
#

Gentoo is really just the distro for masochists

round moss
#

any new software you have to build from source, so it checks for a license

#

you can probably bypass it

hazy laurel
#

I'd hate to miss a month of updates and sit there for a day or two or three just compiling everything

round moss
#

(and well, you can probably also run apimages)

odd sphinx
#

interesting

round moss
#

if you miss a month of updates, you have to reinstall

#

or maybe a bit over a month

hazy laurel
#

Jeez

round moss
#

not exactly sure

odd sphinx
#

wtf

round moss
#

but they do not support large updates

timber mango
#

You guys use any paid software for programming?

odd sphinx
#

no

hazy laurel
#

Well

#

Define paid...

#

because I use PyCharm Professional and what-not

odd sphinx
#

pycharm professional

hazy laurel
#

but I didn't pay for it

#

I should clarify that I'm a student

round moss
#

I use word for writing down notes and such

hazy laurel
#

I don't pirate lmao

round moss
#

which my parents do pay for

#

free software is a cool idea, but I don't think I care that much

odd sphinx
#

same

hazy laurel
#

well tbf if you use Windows or macOS you're basically using paid software

odd sphinx
#

except when i need it

round moss
#

yeah

#

I am debating putting gentoo on my laptop for uni and just use vi for taking notes

#

gotta have a good battery life

hazy laurel
#

but why would you do this

timber mango
#

I downloaded windows 10 for free from their main website

hazy laurel
#

Install Alpine 👍🏽

round moss
#

that could also work

#

or just freeBSD

hazy laurel
#

I don't think that'd help much

#

I doubt it's as optimized

#

Alpine might be a good case for this... considering it's supposed to be incredibly light for use with Docker

round moss
#

honestly, even just fedora workstation would probably be fine. It's mostly the screen that is energy hungry

#

as well as WIFI

hazy laurel
#

I don't think Fedora would be good

round moss
#

alpine as a daily driver seems unwise

hazy laurel
#

They're too GNOME-centric

#

and GNOME is notoriously not very performant

round moss
#

you can install fedora with something other than gnome

#

at least I saw the button in the installer

hazy laurel
#

Yes, but their spins are low quality

round moss
#

ah

hazy laurel
#

their main focus is on GNOME

#

and it shows

fossil pier
#

You dont need a spin to install a desktop enviroment,

jovial island
#

Someone can chat with me I m alone

hazy laurel
#

You'd ideally want a generic desktop

#

but I don't think Fedora has an install for that

#

Honestly, for the most part distro is kind of irrelevant

#

it's pretty much mostly the DE that you have to worry about

jovial island
hazy laurel
#

so openSUSE or Arch might be good picks, because you can customize your installations fairly easily

jovial island
#

hey guys could someone help me out with a code?

fossil pier
hazy laurel
jovial island
#

how do I assign a unique number to an item in a list?

fossil pier
#

So you have a list like ["a","b","c"] and want [("a",0), ("b",1), ("c",2)] ?

hazy laurel
somber belfry
#

you'd want to use UUID too

hazy laurel
#

the library?

somber belfry
#

yes

jovial island
#

basically i want so when the first item appears in the list, it's assigned to the number "1", the second one to number 2, but if the first item appears again, the program would know that this item is number 1

somber belfry
#

for generating the id

#

okay, never mind

hazy laurel
#

I mean it could still work lol

somber belfry
jovial island
#

in another list

hazy laurel
#

Wait

#

Are you not able to use a set for what you're doing?

jovial island
#

so ['Michael', 'James', 'Andrew', 'Josh', 'Michael', 'Josh'] would be [1,2,3,4,1,4]

fossil pier
#

Are you sure you dont want to use a dictionary instead? So you have a mapping from the item/names to numbers?

hazy laurel
#

I'm thinking this might be some X/Y problem

jovial island
#

yeah a dictionary could work better lol

hazy laurel
#

and maybe step back and say what it is you're trying to accomplish

#

because I think using just a set might be able to work if you don't require order or something

somber belfry
hazy laurel
#

Fair haha

#
In [1]: x = [1, 2, 2, 3, 3, 4]

In [2]: set(x)
Out[2]: {1, 2, 3, 4}
jovial island
#

i thought of a better solution

#

what code could assign a number to an item?

hazy laurel
#

You'd want to use a dictionary or a class for that

jovial island
#

but the numbers would have to be going up to 50

hazy laurel
#

or even a tuple/list, I guess

somber belfry
#

a named tuple

#

why do you wanna store the number in another list?

#

Sorry, I'm way too tired to be awake right now

hazy laurel
#

It'd be helpful if we had some clarification as to what you're doing lol

jovial island
#

with a dictionary, is the number forever assigned to the value, or it can be overwritten if a new value is added?

hazy laurel
#

it can be overwritten

jovial island
#

-_- :)))))

#

why is coding so hard? :(((

#

i want it to be simplerrrrr

#

no

hazy laurel
#

Could you maybe explain what it is you're trying to achieve ;-;

odd sphinx
#

yea

jovial island
#

so basically i want to add a bunch of names to a list

hazy laurel
#

uhuh

jovial island
#

and i want to write a program so that each name is the list is assigned to a specific number

fossil pier
#

Something like could work, but this is python so there probably exists some fancy one liner:

result = {}
ident = 0
for item in the_list:
  if not item in result:
    result[item] = ident
    ident += 1
odd sphinx
#

{i: name for i, name in enumerate(names)}

jovial island
#

so if the same name is added to the list again, the program would automatically know the number asigned to that program

#

uni assessment :))))

hazy laurel
#

I see

jovial island
#

but i just struggle to write this

odd sphinx
#

then u can check if such a value already exists in the dictionary

fossil pier
hazy laurel
#

You could probably just use a list of dicts

#

ouch

odd sphinx
#

oof

hazy laurel
#

It's list.index right?

odd sphinx
#

yes

#

damn

#

ok

hazy laurel
#

I might be thinking of list.find

odd sphinx
#

ok

hazy laurel
#

D:

odd sphinx
#

it is defintely index

jovial island
#

yeah maybe a list of dicts would be good

odd sphinx
#

so u allow duplicate names in ur dict? @jovial island

radiant socket
#

oh there's a cool way to do this one

somber belfry
#

Or just use one dict
the key will be the name of the person and the value will be the unique ID

before adding a key to the dictionary, check if the key already exists
if it exists, dont add it
if it does not exist, add it and assign the unique id to the key.

odd sphinx
#

yes

jovial island
#

yeah

#

let me give you an example

#

I would want my program to recognize this

somber belfry
#

does the unique id have to be 1, 2, 3.. etc?

radiant socket
hazy laurel
#

well. I managed to come up with a solution

#

idk how I would... explain it without giving it

jovial island
#

['Michael', 'James'. 'Peter', 'Michael', 'Peter'] = [1, 2, 3, 1, 3]

#

so every name is assigned to a number

#

but if the item appears in the list again, the program would use it's appropriate number

hazy laurel
#

Okay, so list.index() returns the index of the first item it finds in a list

#

or maybe that's any... "indexable"

radiant socket
#

lists

hazy laurel
#

So even if you have multiple of the same item... the index will always be of the first one

fossil pier
hazy laurel
#

You can land on something much more straight-forward with list.index(), though

jovial island
#

yeah that's a good idea

#

thank you 🙂

#

yeah that makes sense

#

if the item appears one in the list, an index is assigned to it

somber belfry
hazy laurel
#

You don't need an if, though

somber belfry
#

why not an ordinary dict?

dusky cliff
#

list.index will probably make it even more complicated

somber belfry
#

unless you mean OrderedSet

hazy laurel
#

or from what I did

dusky cliff
#

I have a solution alrd

radiant socket
#

wait, maybe dict will work now

hazy laurel
#

the actual "solution" is like a single line

nova ember
#

Dicts are guaranteed to preserve their order nowadays

dusky cliff
#

||list(dict.items())[x] \😎||

radiant socket
#

yeah, should work with normal dict

somber belfry
#

Karen said

radiant socket
#

who cares, it's in the reference now

hazy laurel
#

lol

#

all you have to do is make a list of dicts

#

the key the index, the value the item

nova ember
jovial island
#

how can i add the index of an item from one list to another one<

hazy laurel
#

enumerate?

#

Maybe I've mistook what you're wanting

jovial island
#

so the index of a value from list1, how can i append this number to list2?

hazy laurel
#
[{0: 'A'}, {1: 'B'}, {2: 'C'}, {1: 'B'}, {0: 'A'}]

this is the result of what I've got

jovial island
#

this is good, but my program needs to include up to 50 names

#

and random ones

#

so the person would just type in the name, and this name would be assigned to a number

hazy laurel
#

I think you may be overthinking it

odd sphinx
#

yea

hazy laurel
#

The secret lies in list.index()

#
In [1]: x = ["A", "B", "C", "B", "A"]

In [2]: for i in x:
   ...:     print(x.index(i))
   ...:
0
1
2
1
0
odd sphinx
#

hmm

hazy laurel
#

ah, actually.. I think I see the situation

#

if I add another, it'd need to be 3, wouldn't it

odd sphinx
#

defaultdict

radiant socket
#

you get an issue with an input like this, [1, 1, 1, 1, 5]

hazy laurel
#

it'd be 0, 0, 0, 0, 4, yeah?

#

which you'd want 0, 0, 0, 0, 1

radiant socket
#

but it should be 0 (or 1, depending on what you start at) 1

dusky cliff
#

no it should be 0, 0, 0, 0, 1

radiant socket
#

yep, exactly

dusky cliff
#

laggg

#

aaaaaaaaaaa help

hazy laurel
#

okay, but index can still be useful here

dusky cliff
#

I hav a one liner

hazy laurel
#

nevermind. maybe not

dusky cliff
#

unfortunately I cheated with ors

#

wtv

#

its still a oneliner

hazy laurel
#
[{0: 'A'}, {1: 'B'}, {2: 'C'}, {1: 'B'}, {0: 'A'}, {3: 'D'}]

there we go

round moss
#
a = {name: i for i, name in enumerate(dict.fromkeys(l))}
res = [a[name] for name in l]
``` sth like this?
hazy laurel
radiant socket
#

that was my sol, yeah

dusky cliff
#

won't that keep the last occurrence

#

not the first

hazy laurel
#

mine's different

#

oh. but actually not

#

because all I did was not use enumerate in my obsession with list.index

fossil pier
#

I also have a question. I am thinking about creating a special kind of profiler for python. To explore this idea and to see if its feasible, i need to have access to some code to test. Does anyone know about any python based projects that has a good collection of benchmarks? Preferably for longer running tasks.

round moss
#

most web servers have some sort of benchmark

fossil pier
round moss
tribal tinsel
#

Reporting on the birdie. It eats a loooot and shits a lot. The feathers are now bigger. Birdie likes hands because they're warm.

dusky cliff
#

nice

tribal tinsel
#

Well, the eating and shitting parts are not as nice. It's loud when it wants something :D

dusky cliff
#

lol

odd sphinx
#

daily bird reports letsgo

sinful sun
#

#birb channel when

median blade
#

Yooooooo

#

Yes

jovial island
#

no

#

.topic

rustic harborBOT
#
**What made you want to join this Discord server?**

Suggest more topics here!

jovial island
#

Free range help

wide totem
#

what the fuck was i thinking when i coded this

jovial island
#

Girls?

languid osprey
#

PFFT

wide totem
#

i legit coded a database schema into a config file

#

this was dumb

#

so i have to re-rewrite half of my rewrite of the configuration

lucid osprey
#

since pydis was the first server (public server) I joined.

dusky cliff
#

same

lucid osprey
#

I just wanted to join a public server since the only server I joined before this one was my frens' server which is currently dead.

dim root
#

i saw r/python and then saw the discord which was the day i joined this server and discord

#

!u

clever salmonBOT
#

You are not allowed to use that command here. Please use the #bot-commands channel instead.

lucid osprey
#

almost deleted discord until I found this server, and a couple of others too.

dim root
#

hence ^

wide totem
#

fuck pipenv lol

jovial island
#

all my homies use poetry

gaunt wave
lucid osprey
#

what does scalable mean btw?

gaunt wave
#

Scalability is the property of a system to handle a growing amount of work by adding resources to the system. ... In computing, scalability is a characteristic of computers, networks, algorithms, networking protocols, programs and applications.

lucid osprey
#

oh hmm

odd sphinx
#

ye

daring jay
#

Scalability only really matters if you have a backend

lucid osprey
#

I need a few more mins to let that sink in..

gaunt wave
#

@lucid osprey it's like... it shud be like... capable or adding new features and.. thinks

lucid osprey
#

ah got it.

gaunt wave
#

Get it?

#

yah thats it

lucid osprey
#

I remember writing a python file

#

and

round moss
#

scalable doesn't mean extensible, scalable means you can take this from 100 users to 1000000

gaunt wave
#

Capable of scaling... the program in future.. ig.. coz wikipedia thingy doesn make sense

lucid osprey
#

I wanted to add one more functionality to it

gaunt wave
#

welppp

#

plss

lucid osprey
gaunt wave
#

ooooo

round moss
#

what country are you in?

gaunt wave
#

@round moss INDIA

#

but client

#

is from the us

#

u can say the us

#

standards

#

@round moss......

round moss
#

On second thought, I am not the right person to give advice for pricing. Consider asking in #career-advice

gaunt wave
#

No one pops is there :-/

#

pops up*

wide totem
#

But I decided to just

#

Take pipenv and remove it from the project for now lol

odd sphinx
#

@frozen pelican have a doggo

frozen pelican
#

ahhhhhh cute

odd sphinx
#

ikr

frozen pelican
#

yeah

odd sphinx
#

hes such a lad

frozen pelican
#

i like puppies

#

like my fav pets

#

but never had one

#

looking to get one

odd sphinx
#

u should get one

#

i mean

#

ive never had a puppy

median blade
#

same

frozen pelican
#

ok

wheat rock
odd sphinx
#

ey?

wheat rock
#

that's kyoot

#

yours 👀

odd sphinx
#

agree

wide totem
#

wow

narrow sigil
odd sphinx
#

quite

wide totem
narrow sigil
wide totem
#

smeh

jovial island
radiant socket
#

that will have incorrect behavior on certain inputs

fossil pier
radiant socket
#

[1, 1, 1, 2]

fossil pier
radiant socket
#

you would get 3 as 2's id, not 2

#

for one based counting in the id

fossil pier
split flax
#

ok

#

nice

jolly oriole
#

a repo for example

split flax
#

More like.... rice.

jolly oriole
#

fair enough

hoary basalt
#

:0

split flax
#

I know what a fucking repo is.

jolly oriole
#

😮

split flax
split flax
jolly oriole
#

what if the algorithm was the impostor

split flax
#

Imagine.

jolly oriole
#

ejected the algorithm

split flax
#

Fuck 🤣

jolly oriole
#

rip algorithm 2021 to 2021

hoary basalt
#

oh no. everywhere i go, I see the sus word STOP

jolly oriole
#

i know

#

it gives me PTSD

split flax
#

" " - AlgorithmSus 2021

jolly oriole
#

😮

#

back to the general

jolly oriole
#

we need to go help people

split flax
jolly oriole
#

nvm

#

they are all dead

hoary basalt
#

general is dead

jolly oriole
#

yup

steel eagle
#

Amongus/sus is such a dead meme now it's just a calling card for those who are behind the times or just unfunny in general

steel eagle
#

I wish you a very bad day

languid osprey
real forum
wide totem
languid osprey
#

sususu

real forum
#

Tbf everything they said was correct, the meme isn't funny, it's dead, and it's annoying.

languid osprey
#

lmao

wide totem
#

Basically I'm no longer rewriting @vapid maple

languid osprey
#

oh no

#

why

wide totem
#

I'm writing a fresh modmail

languid osprey
#

oh

#

new modmail

wide totem
#

That's mostly compatible with @vapid maple installs 😏

real forum
#

Pog

wide totem
#

because this way I can license the rewrite under MIT or LGPL

real forum
#

Tbf after looking at @vapid maple's source code it's a bit of a mess

wide totem
#

^^^

real forum
#

Python discord modmail when?

wide totem
#

I redid the entire bot configuration

#

And then redid the other code

#

And then when I got to the threads code

#

And I could run self.threads.bot.threads.bot...

real forum
#

lol

wide totem
#

I gave up on that code and started a totally new bot

#

Hm

#

It actually runs atm

#

It doesn't do anything other than connecting to the gateway

#

Next step is to add the database

real forum
#

You know, I looked at most of the bots source, and I didn't find a single on_message event

wide totem
#

It's in the bot file iirc

#

Line 1125...

real forum
wide totem
#

It's in the main folder

clever salmonBOT
#

bot.py line 1125

async def on_message(self, message):```
real forum
#

Nvm I found it

wide totem
#

Reason 2 for a rewrite, a gigantic 2k+ line main file

#

That includes bot definition and most of the thread logic

#

But not ALL of it since half of that is in the core.thread file

real forum
#

Yeah I don't get why most of it isn't in threads.py

wide totem
#

EXCEPT core.models also includes half of the thread model

real forum
#

Ugh I keep seeing the %s method and it pains me

wide totem
#

AND in core.threads the ThreadsManager has a attribute of bot!!

wide totem
#

That's what pains u?

#

Smhhhhh

real forum
#

Well ehh

wide totem
#

Lol

rigid oyster
#

Off topic but is the title of this channel sarcastic?

wide totem
#

Probably

rigid oyster
#

xD

wide totem
#

This is where the rewrite is @real forum

#

Look at that config file 🧑‍🍳 💋

#

Pydantic, toml, and dotenv used automatically load from a config-default.toml, a config.toml, and a .env file

real forum
#

mmm

#

good shit

jovial island
#

microsoft teams is terrible software

hollow heart
#

@jovial island do pls share more, what do you find its weaknesses are?

jovial island
#

I'm on mobile so bear with me

#

why do you have a bear with you

#
  1. teams is not a native application:

of course, it is an electron app, meaning it'll be way slower if implemented incorrectly, and it relies on layers and layers of software to display things correctly, which of course means overhead

#
  1. teams is full of Microsoft fuckery

since teams isnt a native application, and it embeds things like power point and word, it was very easy for Microsoft to simply load the webpage version of those two, and on teams for some reason the toolset for those embedded apps is very restricted, try to edit a word document in teams for example

#
  1. not asynchronous

teams loads every bit of information from the database in the main thread, whenever you go fetch something like your messages, team list, team chat whatever

#

and that leads us to the last point, teams doesn't cache anything, it fetches everything again and again and never bad a local copy of a document, you can guess how well that goes.

#

for people with fast internet connections and slow response times they might not feel the effects of these poor implementation choices

#

but me with my puny 10mbps uplink cries about it every day

#

@hollow heart

scarlet totem
#

wait I thought that was a fork nvm

jovial island
#

imagine not having a message cache and loading in 1000 messages each time you pop up a new tab

wide totem
#

But due to licensing and the current state of the code of @vapid maple, it's more efficient to rewrite from scratch.

#

Rewriting from nothing means I can safely license it with MIT

#

Since all code is mine or is from other bots with MIT licenses

hollow heart
wide totem
hollow heart
#

instead we're trying to move to zoho cliq bc we also have the zoho one subscription but.. i don't love cliq it just feels like a barely completed application to me. I'm not technical enough to outline the faults like you did though.

is there a dream work-messaging app for you?

scarlet totem
wide totem
#

yea

#

now, it will be compatible with @vapid maple

wide totem
#

probably will, anyhow

#

motor relies on the other one

sweet meteor
#

no, microsoft teams sucks

odd sphinx
#

oof'

sweet meteor
#

pls don't use it if you have that option

hot verge
#

of course it does suck everything from microsoft except Task Manager and Ms Paint does

slow valve
#

indeed Microsoft Teams is great software

misty blaze
#

a

cerulean panther
#

.topic

rustic harborBOT
#
**What would you do if you know you could succeed at anything you chose to do?**

Suggest more topics here!

jovial island
#

Wait is this channel a joke ?

cerulean panther
#

yes

jovial island
#

Ah okay

cerulean panther
jovial island
#

Okay

cerulean panther
#

.topic

rustic harborBOT
#
**What's the best pastry?**

Suggest more topics here!

cerulean panther
fickle thorn
#

ye teams is great

hybrid maple
#

.topic

rustic harborBOT
#
**What book do you highly recommend everyone to read?**

Suggest more topics here!

idle comet
sinful sun
#

Time to build another crud app again i guess

#

I hate life

sinful sun
odd sphinx
#

lol

worn sluice
#

idk

#

seems like u need to automate

#

some boring stuff

radiant socket
#

educated by tara westover

proper python
#

wtf

dusky cliff
#

?

proper python
#

it doesnt fully collapse

dusky cliff
#

o lol

proper python
#

how do i make it fully collapse

median blade
#

what is {% %}

proper python
#

django syntax

daring jay
#

In Django? It indicates their template tags

median blade
#

o

languid osprey
#

dawn

#

new pfp

delicate lion
#

it is singular bongocat

#

he is not bongoing

#

just sittin there with his paw in the air

hot pulsar
#

🐱

daring jay
#

bongocat

odd sphinx
#

no

#

theres no bongo

#

therefore it is just a cat

bold zinc
#

hi

jovial island
#

hi

cerulean panther
bold zinc
#

i am 13 years old boy

#

pls i want to learn code

#

can you help me

cerulean panther
clever salmonBOT
#
Resources

The Resources page on our website contains a list of hand-selected learning resources that we regularly recommend to both beginners and experts.

bold zinc
#

thx

cerulean panther
#
>>> ᓚᘏᗢ="cat"
>>> print(ᓚᘏᗢ)
cat

hmmm

rigid echo
#

mhm

bold zinc
#

what is this ?

steel eagle
#

The python discord off topic channel

wide totem
#

@rare moat is back y'all

rare moat
#

sup.

urban narwhal
#

ouch, took me 3 hours of fiddling, but I made it work! Spotify api export of all my playlists and imported it to sqlite db. Unicode tables is still a challenge. Also the max request of 100 each time

blissful coral
#

!rule 6

clever salmonBOT
#

6. Do not post unapproved advertising.

blissful coral
urban narwhal
#

Who did advertising?

#

Not me

blissful coral
#

lol, the staff breaking their own rules

urban narwhal
#

¯_(ツ)_/¯

echo fern
blissful coral
#

I can finally legitimately charge the admins for the voilation of their own rules 😎

dusky cliff
#

👀

#

what happened here

odd sphinx
#

same

slow valve
#

same

jovial island
#

ok

dusky cliff
#

@blissful coral explainnnnnn

#

i need answers

dusky cliff
#

lmao

#

well played

jovial island
#

It's still on tho

slow valve
#

lol

slow valve
#

fax != advertise

jovial island
#

Faxmachine

blissful coral
#

google meet for me 🚀

slow valve
#

🤮

dusky cliff
#

discord vc lemon_smug

slow valve
#

lol

blissful coral
#

zoom is fair for me

#

but then I don't have online classes anymore

slow valve
#

zoom is the worst of all

idle comet
#

BigBlueButton > anything else

blissful coral
#

can't comment - Ive forgotten them all

#

thats what you get for browsing youtube during online classes

slow valve
#

lol

jovial island
#

I love myself

slow valve
#

nice

slow valve
cerulean panther
#

oof

#

0%

jovial island
sinful sun
#

Now kiss already
Scores 0%
Which one is it, bot

#

WHICH ONE

tribal tinsel
round moss
#

@pastel nest added some python questions to the doc.

sullen estuary
#

I like your new pfp @bold dove

fallen bramble
#

a

upbeat sandal
lone mist
#

could we not have blatant lies in channel names please?

echo fern
#

wa

pastel nest
wide totem
pastel nest
#

@round moss you're singlehandedly carrying the entire next pr. thank you soooo much, these are incredible contributions :) i just finished checking your python questions, on to the cs!

wide totem
#

….

#

i just

#

wtf

#

i deleted discord

#

i reinstalled discord

#

I STAYED SIGNED IN

daring jay
#

Nice

wide totem
#

no bad

#

i found malware in my discord install lol

daring jay
#

Oof

#

That does not sound good

wide totem
daring jay
#

Nice

#

Did you install Discord from the official site?

wide totem
#

yes

#

i installed it many moons ago

#

it was discord which downloaded it

#

file: C:\Users\\AppData\Roaming\discordcanary\Cache\f_004e1a

#

mm

wide totem
daring jay
#

Idk

#

I've dealt with enough code errors today that I can't think very well

pastel nest
wide totem
#

@grim seal nice channel name

daring jay
#

Why are you replying to them in the wrong channels

wide totem
#

why are you pointing that out

daring jay
#

Because I want to

grim seal
wide totem
#

i know it was

grim seal
#

why not ping there lol

wide totem
#

you've been well versed in python for many years

grim seal
#

soon i'll bar your permissions from ot2

wide totem
#

its ot0

#

why would i use ot0

wide totem
hazy laurel
#

haha get rekt

languid osprey
#

lmao

echo fern
languid osprey
#

ooh

daring jay
#

That's amazing!

languid osprey
#

yep

echo fern
#

I've reached the point where the poor Rust function actually runs for a decent fraction of a second, lol

#

when I use a high MaxIters and horizon

#

still works fine, though

daring jay
#

Only programmers would think a second is long

echo fern
#

users would too if they were using it 😛

wide totem
#

oh good i can chat here again

echo fern
#

by the way, the window is resizable!

#

and the viewport automatically adjusts to it - as in, if you resize the window to half the size, fewer fixels will be calculated each time and performance will be better

wide totem
#

hm.…

#

i wonder what will break here

#

LOL

#

tl;dr everything

dusky cliff
#

my otn 😌

languid osprey
#

Lol

raw raptor
odd sphinx
dusky cliff
#

black and white are colours too smh

odd sphinx
#

how far can u zoom in

#

shouldnt u reach a float limit

#

especially if ur using c#

odd sphinx
#

or hes using doubles

lucid osprey
#

this ot name is too good

vague belfry
#

Hey! How do I pass a 2d array to a function?
#include<bits/stdc++.h>
using namespace std;

// Print the distance of nearest cell
// having 1 for each cell.
void printDistance(int mat[N][M])
{
int ans[N][M];

// Initialize the answer matrix with INT_MAX.
for (int i = 0; i < N; i++)
    for (int j = 0; j < M; j++)
        ans[i][j] = INT_MAX;

// For each cell
for (int i = 0; i < N; i++)
    for (int j = 0; j < M; j++)
    {
        // Traversing the whole matrix
        // to find the minimum distance.
        for (int k = 0; k < N; k++)
            for (int l = 0; l < M; l++)
            {
                // If cell contain 1, check
                // for minimum distance.
                if (mat[k][l] == 1)
                    ans[i][j] = min(ans[i][j],
                         abs(i-k) + abs(j-l));
            }
    }

// Printing the answer.
for (int i = 0; i < N; i++)
{
    for (int j = 0; j < M; j++)
        cout << ans[i][j] << " ";
}

}

// Driven Program
int main()
{
int T;
cin>>T;
while(T--){
int N,M;
cin>>N>>M;
int mat[N][M];
for(int i=0;i<N;i++)
for(int j=0;j<M;j++)
cin>>mat[i][j];
printDistance(mat);
}
return 0;
}
It shows me that N and M were not declared in void printDistance(int mat[N][M])
How can I declare it before hand when I am supposed to get it as input in my main

#

Sorry for this C++ 😦

#

But might be you guys can help as always:)

dusky cliff
#

if its anything like java, it should be void printDistance(int[][] mat)

#

or maybe void printDistance(int mat[][])

#

also please use codeblocks when posting code

odd sphinx
#

yes

dusky cliff
#

like so
```cpp
code
```

odd sphinx
#

precisely

dusky cliff
#

you're missing a few 69s in your username

odd sphinx
#

lol

round moss
#

you can't have VLAs in C++, no?

jovial island
#

i don't think you can

#

they are optional

#

afaik only standard that forces VLA's to exist is C99

round moss
#

huh, it does work in C++ with gcc, but not with msvc

jovial island
#

yes, gcc has all the non-mandotory stuff while msvc doesn't have any of em

#

gcc adds more awesome features too

round moss
#

even clang has VLAs

#

well, regardless, you can't have a VLA as a function parameter

jovial island
#

you have pointers

#

you know

#
int func(int *arr)
{
}```
#

and then you can pass

#
int arr[45] = {4};
func(arr);
round moss
#

you will also have to pass the size if you want it to be useful

#

but yes, that would work

jovial island
#

well yeah

dusky cliff
#

wait what
what does int arr[45] = {4}; do

#

create a 45 length array with 1 item?

jovial island
#

it creates a array of length 45 with all elements being 4

odd sphinx
#

yes

dusky cliff
#

o ic

round moss
#

it should create an array whose first element is 4 and the rest 0

jovial island
#

oh yeah, sorry

#

i just woke up

#

pfp change?

#

me, yes

#

it's been a while with the mordecai one

#

so i decided to change it

echo fern
echo fern
odd sphinx
#

oh i see

#

using the number of iterations?

echo fern
#

like, what would each color mean

odd sphinx
#

the hue of each colour would map to the number of iterations

#

eh?

echo fern
#

currently I'm using the shade of gray to mark the iteration count

odd sphinx
#

yea

echo fern
#

because all three colors would be the same

odd sphinx
#

no using hsv

echo fern
#
pub fn calculate_mandelbrot(
    x_min: F,
    x_max: F,
    y_min: F,
    y_max: F,
    width: u32,
    height: u32,
    max_iters: u32,
    horison: F,
    shades_max: u8,
) -> Array2<u8> {
    assert!(shades_max >= 1);
    let horison_sq = horison.powi(2);
    let fun = |(i, j), el: &mut u8| {
        let y = y_min + (i as F) * ((y_max - y_min) as F / height as F);
        let x = x_min + (j as F) * ((x_max - x_min) as F / width as F);
        let c: C = Complex::new(x, y);
        let mut z: C = Complex::default();
        let mut converged = true;
        let mut iter: u32 = 0;
        while iter < max_iters {
            z = z.powi(2) + c;
            if z.norm_sqr() >= horison_sq {
                converged = false;
                break;
            }
            iter += 1;
        }
        if !converged {
            let color: u8 = (iter as u8 % shades_max) * (255 / shades_max);
            *el = color;
        }
    };
    let mut img: Array2<u8> = Array2::zeros((height as usize, width as usize));
    Zip::indexed(&mut img).par_for_each(fun);
    img
}

here's my current impl

#

hmm, hsv... what'd be the hue, saturation and v?

odd sphinx
#

saturation full, lightness half and hue the number of iterations

echo fern
#

hmm

#

maybe, maybe

odd sphinx
#

lightness can be anything

#

except 0

#

cuz

#

well

echo fern
#

let's see what happens when I do that

#

might need to figure out how to make hsv images with image first though

#

or, rather, how to recode them into RGB

#

because I think it's easier to do on the Rust side than on the C# side

odd sphinx
#

are u using Bitmap in c#?

echo fern
#

yeah, I have to use WritableBitmap even because the normal one doesn't seem to support loading grayscale (1 byte/pixel) images

#

but with an RGB image I can probably use the normal one (passing it a stream made from the array)

#

ah, first I need to figure out how, in Rust, iterate only over 2 dimensions of an array...

dusky cliff
jovial island
#

50

#

1

echo fern
#

how long does it take to index one tiny package aaaaa

#

ah, I see, it's because of my sins

sullen estuary
echo fern
#

how does palette even work

#

and it wants float32 components, u8 is a no-no

tranquil ridge
#

wait whot

echo fern
#
            let color: f32 = (iter as u8 % shades_max) as f32 / shades_max as f32;
            let pxl: Hsv<Srgb, f32> = Hsv::from_components((color, 0.5f32, 1f32));
            let rgb: LinSrgb<u8> = LinSrgb::from(&pxl);
            el[0] = rgb.red;
            el[1] = rgb.green;
            el[2] = rgb.blue;

not pictured - the 10 errors I get from this snippet