r/AskComputerScience • • Oct 30 '19

Why is data transferred between cache and RAM in blocks?

30 Upvotes

Why blocks?


r/AskComputerScience • • Aug 13 '19

How to: Deep Fakes

30 Upvotes

I recently came across this deep fake video: https://www.youtube.com/watch?v=bPhUhypV27w

And ever since, I have been in shock. I am obsessed and want to learn how I can create such videos. How/Where do I begin? What do I need to learn, in terms of programming and other academic knowledge before I can start to create such deep fakes?

Background: I have strong knowledge of math (MSc). I can program in C++ and am half decent in R.

I expect massive gaps in my knowledge so this will be more of a long term thing I'll do as a hobby.

P.S: First time posting here, if there is a more appropriate subreddit for this question, please let me know. Thanks!


r/AskComputerScience • • Aug 02 '19

How does a computer receive and then process data from an input, and output data?

30 Upvotes

Say if I have a keyboard connected via USB to my PC, a key press will send the binary version of the ASCII character to the computer, an application and the operating system will incorporate it into a program - but how does it get sent to main memory, as instructions can only be executed from there - if there was no program, would it simply be sent to main memory and then be executed?

And secondly, how would a CPU output something i.e. a monitor? Are there specific instructions in it's instruction set to output to a specific connection?


r/AskComputerScience • • Jul 14 '19

Please recommend an approachable book for Computer Architecture.

30 Upvotes

Just learnt that I'm going to study Computer Architecture next semester that's based on a book called "The Essentials of Computer Organization and Architecture", and I just read the reviews for it and it seems terrible for students, people hated it for being too cramming, long and complicated and hated that their college required it.

I'm looking for a good, approachable alternative for Computer Architecture so that I could read it now before I take the class to have some foundation on the course and actuallyunderstand what it's about before having to tackle it.

Here's what it says about the knowledge and skills students will develop after taking the course for more context:

  1. the definition of computer architecture

  2. the major components of modern computer architecture

  3. the functionality and trade-offs of several cache memory designs

  4. the instruction pipeline

  5. the differences between RISC, CISC, and Superscalar architectures

  6. parallelism in terms of both single and multiple processors

  7. the issues and trade-offs involved in instruction set design

  8. the unique architectures of multiprocessors and multicomputers

  • Introduction & vocabulary, History of computer architecture, Overview of computer organization

Course major topics:-

  • Overall CPU organization, High-level issues in CPU design, Memory Hierarchy and cache, External memory, RAID organization of hard disks.

  • Representing information digitally, Instruction Sets [CISC/RISC], Addressing Modes.

  • Pipeline design, Branch prediction , Superscalar Design

  • Operating System Issues, virtual memory, Paging & Segmentation

  • Parallel Processing , Cache coherence in parallel computing

  • Parallel computer architectures, Distributed computing


r/AskComputerScience • • Mar 06 '19

Best way to learn CS without college?

30 Upvotes

We have all heard of bootcamps, MIT open courseware, etc. What are some other good ways to ace a interview or generally get a job in CS without having a related degree or degree at all?

Thank you guys so much for all your help thus far!

EDIT: on top of this what are the basics a CS student knows after graduation. I get some may know alot and some not so much. But what is the core of a CS degree. Also what are a few concentrations that are in high demand currently ? (machine learning, AI etc etc.)


r/AskComputerScience • • Feb 01 '19

Are computer science jobs actually in demand?

30 Upvotes

Seeing how #learnToCode is trending, it got me thinking again. I've always enjoyed programming, but with how much it's been pushed, I feel like there would be an excess of programmers, so I've always ruled out programming as a career. Many people cite the number of jobs in a given field as evidence for how in demand it is, but this doesn't even make any sense, since it doesn't take into account how large the workforce is. So I'd like to ask those of you who have programming jobs, how much competition is there in snagging a job?

Sorry if this was already asked, I skimmed a search of this sub and my eyes didn't catch anything

Edit: I would like to ask another question. Do you think we're in a "Tech Bubble 2.0", similar to the Dot-Com Bubble?


r/AskComputerScience • • Jan 10 '19

If you hypothetically were able to time travel a completely up to date phone 3-5 years ago, how much of it could actually function (different apps/social media) on the “past internet “

30 Upvotes

r/AskComputerScience • • Dec 29 '18

Do you guys agree with this guy's post?

30 Upvotes

Saw this on an AskReddit post. As a senior in high school applying to universities as a CS major, I'm a lil worried.

I'm willing to wager thousands of prospective CS students are those who found a bit of interest in programming, and then saw the amount of money a "software programmer" could make (or perhaps vice-versa). They've always been "good" with computers, and that AP CS class they took last year really piqued their interests. They researched further and found "software/development managers" could make over 200k a year, and suddenly they envision themselves sitting at a computer all day, hacking away, maybe even working remotely from home, and making 300k a year. And to add even more weight to the potential disillusionment, many of these soon to be CS majors hope that maybe, just maybe, they'll somehow create the next Snapchat or Facebook or Flappy Bird or Bitcoin or Unturned or whatever new product that allows them to sit down, rake in millions, and enjoy an early retirement in the "bustle and hub" of California's Silicon Valley. That's not to say it can't happen. By all means aim high. But you don't see nearly every prospective lawyer eyeing a spot on the Supreme Court, or every prospective biology major with realistic goals to cure cancer. A CS degree is slowly becoming the new business degree of the 21st century: I don't know what the hell I want to do in life, I like money, and I guess I've always been kind of good at math, so I'll just major in CS and I'll probably be rich or something. Check any school's available undergraduate data. Computer Science, or some form of it, is most likely one of the 3 largest majors on campus, and almost certainly their most impacted major. For all prospective CS majors here: be wary. CS is going to become infinitely more competitive in the coming decade (much more than it already is). Just stay ahead of the curve and you'll be fine.


r/AskComputerScience • • Nov 30 '18

Is Python in space? Are any rovers, probes, satellites coded in python?

30 Upvotes

r/AskComputerScience • • Nov 17 '18

As a newbie with programming, what conventions for making larger scale projects should I know so I do them from the start?

30 Upvotes

r/AskComputerScience • • Nov 08 '18

What is your programming niche?

30 Upvotes

I'm a junior CS student. I like CS and programming because I like to build what I think of and see it in action. But what really drives me is building something that someone might use. Because of this, I've tended to do lots of web/mobile application programming projects but have found them to become boring and the types of things that I learn seem uninteresting or easy to pick up on. If I find something that isn't very easy to pick up on, I have to decide whether or not it's worth my time to pick up the skill, or find a different one because it might not fit what I want to do with my projects.

I'm by no means an expert web/mobile programming. I guess my problem is that I really don't know what I want to do for work when I get out of college (some type of programming of course).

I feel like I've plateaued in terms of learning. And I don't know why because I know, that I don't know basically anything compared to the amount of things there are to learn for CS. So maybe plateaued isn't the right word. I've hit fork in the road. Do I continue with web/mobile, or learn ML/AI, AR, or something else? I want to discover something new. When I first starting programming it was like I had the entire world to discover. But now it's framework after framework or package manager after package manager. It's getting repetitive.

That must be it. I want to discover something new.

EDIT: I just wanted to add that I'm not a beginner, just because some responses seem like very beginner web/mobile dev advice. I can write/build full web/mobile applications (front and backend). I would describe myself as "experienced" I guess, but not expert.


r/AskComputerScience • • Oct 09 '18

Open Source Environmental Projects?

30 Upvotes

I have been getting a bit bummed out after reading a lot about our planets environmental challenges recently such as:

Guardian: Global Warming Must Not Exceed 15c Warns Landmark UN Report

BBC: Final Call To Save The World From 'Climate Catastrophe'

Does anyone happen to know of any open source projects or ideas I (a somewhat recent Computer Science graduate) can contribute to during my free time to help better our planet. I'm hoping to find anything I could do to help, whether it's something more simple such as raising awareness or something more complex like developing a more permanent solution/technology.

I'm rather new to posting so if this isn't the best place to ask I will be happy to redirect my question to the proper place.


r/AskComputerScience • • May 27 '18

At a level above the very basic, how does the process of compiling work?

30 Upvotes

So far as I know, I already know the laymen-level basics of the process...compilers translate the given program into Assembly, and it's assembled from there into machine code.

But as a CS student, I'd love to have a slightly more detailed understanding of how that translation takes place, and how it is that compiled programs can often be run on computers with different CPUs, when the variant of Assembly is dependent upon a given CPU. I'm looking to gain more insight into the process generally, and perhaps a better window into how one might write a compiler (or language), assuming those topics are sufficiently connected.


r/AskComputerScience • • Feb 06 '18

Were there any programming languages Edsger Dijkstra actually liked?

30 Upvotes

I see quotes all over the internet in which Edsger Dijkstra throws shade at some programming language or another (Fortran, BASIC, COBOL, etc). I know he was primarily a pen-and-paper CompSci theory guy, but is there any record of him actually expressing admiration for a particular language?


r/AskComputerScience • • Apr 03 '16

Are AND, OR, XOR logic gates just conceptual abstractions for deeper understanding, or are they actual physical structures inside computers?

30 Upvotes

If so, what do they look like and what are they made out of?

Thanks!


r/AskComputerScience • • Dec 11 '15

How much of computer science was discovered before the first computers? (Crosspost from AskHistorians)

Thumbnail
reddit.com
30 Upvotes

r/AskComputerScience • • Nov 23 '15

Do computers make calculation errors?

30 Upvotes

If computers can make billions of calculations per second, is there an expected calculation error rate they make? If so, is there some sort of correction process? If the calculations are really just tiny jolts of electricity going through logic gates, is there ever chance for an error? If I give excel 100,000 cells to perform a calculation on, is it possible for one of the calculations to be incorrect mathematically?

Thank you.


r/AskComputerScience • • Nov 06 '13

Running into conceptual issues relating to computer science? Check out /r/CSELI5 - it's "Explain Like I'm Five" but for Comp Sci!

30 Upvotes

www.reddit.com/r/csELI5

I've been teaching myself programming and computer science for a couple years now and the biggest hurdle for me has always been trying to understand new concepts. This sub, at least how I see it, offers a place for people who need that little extra push before fully understanding a new concept or topic.

This is my first created sub so be gentle :)

All advice and criticism is welcome! I hope to see some of you there!


r/AskComputerScience • • Dec 13 '25

Could videogames allow for much better physics if graphic quality was significantly cut down?

29 Upvotes

Title


r/AskComputerScience • • Aug 24 '25

Why Does Nvidia Call Each CUDA Pipeline Like a "Core"?

29 Upvotes

In 7000-9000 series AMD Ryzen CPUs, each core has 48 pipelines (32 fma, 16 add). Even in older Intel CPUs, there are 32 pipelines per core.

But Nvidia markets the gpus as 10k - 20k cores.

CUDA cores:

  • don't have branch prediction

  • have only 1 FP pipeline

  • can't run a different function than other "core"s in same block (that is running on same SM unit)

  • any __syncthreads command, warp shuffle, warp voting command directly uses other "core"s in same block (and even other SM units in case of cluster-launch of a kernel with newest architectures)

  • in older architectures of CUDA, the "core"s couldn't even run diverging branches independently

Tensor cores:

  • not fully programmable

  • requires CUDA cores to be used in CUDA

RT cores:

  • no API given for CUDA kernels

Warp:

  • 32 pipelines

  • shuffle commands make these look like an AVX-1024 compared to other x86 tech

  • but due to lack of branch prediction, presence of only 1 shared L1 cache between pipelines, its still doesn't look like "multiple-cores"

  • can still run different parts of same function (warp-specialization) but its still dependent to other warps to complete a task within a block

SM (streaming multiprocessor)

  • 128 pipelines

  • dedicated L1 cache

  • can run different functions than other SM units (different kernels, even different processes using them)

Only SM looks like a core. A mainstream gaming gpu has 40-50 SMs, they are 40-50 cores but these cores are much stronger like this:

  • AVX-4096

  • 16-way hyperthreading --> offloads instruction-level parallelism to thread-level parallelism

  • Indexable L1 cache (shared-mem) --> avoids caching hit/miss latency

  • 255 registers (compared to only 32 of AVX512) so you can sort 250-element array without touching cache

  • Constant cache --> register-like speed for linear access to 64k element array

  • Texture cache --> high throughput for accesses with spatial-locality

  • independent function execution (except when cluster-launch is used)

  • even in same kernel function, each block can be given its own code-path with block-specialization (such as 1 block using tensor cores and 7 blocks using cuda cores, all for matrix multiplications)

so its a much bigger and far stronger core than what AMD/Intel has. And its still more cores (170) for high-end gaming GPUs than high-end gaming CPUs (24-32). Even mainstream gaming GPUs have more cores (40-50) than mainstream gaming CPUs (8-12).


r/AskComputerScience • • Aug 08 '24

Why can virtual assistants like Alexa say "I don't know" but LLMs like chatgpt fabricate answers when faced with knowledge gaps?

29 Upvotes

I'm not really sure if this is a stupid question or not, or whether it belongs here, so thank you in advance for reading and/or redirecting me.

AI and AI-adjacent things have been a recent topic of debate in my writing group. People are afraid. I have tried explaining chatgpt to them, how it works and why (at least for now) their fears are unfounded, but I'm at risk of going off topic there.

Several of them have an Alexa or other AI assistant, which admit when they can't answer a question. I don't know anything really about these models. How is it different to an LLM? Why and how do they create their answers? Are their answers not based on the same pool of data?

Thanks.


r/AskComputerScience • • Apr 06 '23

Linear Algebra book for Machine Learning

29 Upvotes

Hello,

I wrote a conversational style book on linear algebra with humor, visualisations, numerical example, and real-life applications.

The book is structured more like a story than a traditional textbook, meaning that every new concept that is introduced is a consequence of knowledge already acquired in this document.

It starts with the definition of a vector and from there it goes all the way to the principal component analysis and the single value decomposition. Between these concepts you will learn about:

  • vectors spaces, basis, span, linear combinations, and change of basis

  • the dot product

  • the outer product

  • linear transformations

  • matrix and vector multiplication

  • the determinant

  • the inverse of a matrix

  • system of linear equations

  • eigen vectors and eigen values

  • eigen decomposition

The aim is to drift a bit from the rigid structure of a mathematics book and make it accessible to anyone as the only thing you need to know is the Pythagorean theorem, in fact, just in case you don't know or remember it here it is:

There! Now you are ready to start reading !!!

The Kindle version is on sale on amazon :

https://www.amazon.com/dp/B0BZWN26WJ

And here is a discount code for the pdf version on my website - 59JG2BWM

www.mldepot.co.uk

Check a sample here

https://drive.google.com/file/d/1xzK9HtT2gGh8RvMlvnkALu8eSbmgjFeD/view

I also have a youtube channel where I will be posting videos of the book's content

https://www.youtube.com/@MLdepot

Thanks

Jorge


r/AskComputerScience • • Mar 12 '22

What is the reason behind "katana" as the package name of the Facebook Android App?

29 Upvotes

Facebook's package name for Android App is com.facebook.katana. The first two parts com and facebook make sense and that's normal. But why katana as the last part of the package name? Is there any story or reason behind it?

And Also Messenger App has the package name is com.facebook.orca. In which orca raises the same questions. Any story for that?

AFAIK, A katana is a Japanese sword and an orca means killer whale.

Thanks in Advanced.


r/AskComputerScience • • Dec 22 '21

When and why Computer Science separated from Mathematics?

29 Upvotes

It seems to me that at this time mathematicians and computer scientists are different kinds of people and different kinds of societies. Different titles, different slang, different hierarchy, different venues… This is strange because:

  • Computer Science is Mathematics. There is computation, definition, theorem, proof. The method is mathematical and the outcome is mathematical. Physics has its own methods. (Experiment.) Philosophy has its own methods. (I am not sure what they are, but clearly mathematical proof is not the chief among them.) But Computer Science has exactly the same methods as Mathematics!

  • Computer Science is a great success of Mathematics. A century ago, Engineering was entirely based on Physics and, consequently, on the Calculus of Infinitesimals. These days, much of Engineering is Software Engineering. And modern Software Engineering is all abstract and precise. If Mathematics needs a justification, the success of Software Engineering is the best one one can ask for. All the big names — Alan Turing, Claude Shannon, John Von Neumann, and so on — were mathematicians. But this monumental achievement is ascribed to this new area called Computer Science instead.

At the same time. Mathematics at its most fashionable seems to be essentially a never-ending study of numbers and polynomials in the setting of the Zermelo-Fränkel Set Theory. Consider the Constructive Analysis of Errett Bishop and allies. It is a wonderful idea… that was delegated to a few researchers in Computer Science. Same for the Type Theory of Martin-Löf. His lectures now live as a scan of a typewriter draft with hand-written symbols. Apparently it is not even worth type setting. And this is the cornerstone of much of the modern Computer Science!

What happened? How can this be explained?

One possible answer, of course, is that my observations are all wrong. Please help me get a better view of things if you think so!