Requirements

Work through College Board Unit 4… blog, add definitions, and pictures. Be creative, for instance make a story of Computing and Networks that is related to your PBL experiences this year.

How a Computer Works

As we have learned, a computer needs aa program to do something smart. The sequence of a program initiates a series of actions with the computers Central Processing Unit (CPU). This component is essentially a binary machine focussing on program instructions provided. The CPU retrieives and stores the data it acts upon in Random Access Memory (RAM). Between the CPU, RAM, and Storage Devices a computer can work with many programs and large amounts of data.

List specification of your Computer, or Computers if working as Pair/Trio

  • Processor GHz: 1.99 GBz
  • Memory in GB: 16 GB
  • Storage in GB: 475 GB
  • OS: Windows 11

Define or describe usage of Computer using Computer Programs. Pictures are preferred over a lot of text. Use your experience.

  • Input devices: keyboard, mouse
  • Output devices: speaker, screen
  • Program File: vscode, google chrome
  • Program Code: .py files, .ipynb files
  • Processes:
  • Ports: USB, Audio jack,
  • Data File: .PNG files, .CSV files
  • Inspect Running Code:
  • Inspect Variables

Computer Hardware

The Internet

Watch/review College Board Daily Video for 4.1.1

  • Essential Knowledge
    • A computing device is a physical artifact that can run a program. Some examples include computers, tablets, servers, routers, and smart sensors.
    • A computing system is a group of computing devices and programs working together for a common purpose.
    • A computer network is a group of interconnected computing devices capable of sending or receiving data.
    • A computer network is a type of computing system.
    • A path between two computing devices on a computer network (a sender and a receiver) is a sequence of directly connected computing devices that begins at the sender and ends at the receiver.
    • Routing is the process of finding a path from sender to receiver.
    • The bandwidth of a computer network is the maximum amount of data that can be sent in a fixed amount of time.
    • Bandwidth is usually measured in bits per second
  • Complete Vocabulary Matching Activity. Incorporate this into your learnings from year. To analyze measure path and latency use traceroute and ping commands from Linux Terminal.
Term Definition
Path sequence of connected devices starting at sender ending at receiver
Route Process of finding path from sender to receiver
Computer System group of devices and programs working towards common purpose
Computer Device physical device that can run program i.e. computer, phone, laptop etc.
Bandwidth max amount of data that can be sent in a certain time
Computer Network group of devices capable of sending or receiving data

Watch/review College Board Daily Video 4.1.2

  • Essential Knowledge
    • The internet is a computer network consisting of interconnected networks that use standardized, open (nonproprierary) communication protocols.
    • Access to the internet depends on the ability to connect a computing device to an internet connected device.
    • A protocol is an agreed-upon set of rules that specify the behavior of a system.
    • The protocols used in the internet are open, which allows users to easily connect additional computing devices to the internet.
    • Routing on the internet is usually dynamic; it is not specified in advance
    • The scalability of a system is the capacity for the system to change in size and scale to meet new demands.
    • The internet was designed to be scalable
    • Information is passed through the internet as a data stream. Data streams contain chunks of data, which are encapsulated in packets.
    • Packets contain a chunk of data and metadata used for routing the packet between the origin and the destination on the internet, as well as for data reassembly.
    • Packets may arrive at the destination in order, out of order, or not at all
    • IP, TCP and UDP are common protocols used on the internet.
    • The world wide web is a system of linked pages, programs, and files.
    • HTTP is a protocol used by the world wide web
    • The world wide web uses the internet
  • Draw a diagram showing the internet and its many levels. A preferred diagram would use your knowledge of frontend, backend, deployment (GitHub Page, AWS, EC2, Docker, Nginx, Certbot, DNS, APIs).
                                              User
                                               |
                                               |
                                               V
                                         Frontend
                                        Web Browser
                                               |
                                               |
                                               V
                                         Backend
                                       Web Server
                                               |
           ___________                       |
          |           |                      V
          |  GitHub   |                  Deployment
          |  Pages    |                 Technologies
          |___________|                      |
                 |                            |
                 |                            V
                 |                       Infrastructure
                 |                        Technologies
                 |                            |
                 V                            |
           AWS EC2 Instances                  |
                 |                            V
                 |                      Containerization
                 |                    Technologies
                 |                            |
                 V                            |
               Docker                         |
                 |                            V
                 |                        Proxy Server
                 |                   (e.g., Nginx)
                 |                            |
                 V                            |
               Certbot                        |
                 |                            V
                 |                         DNS
                 |                            |
                 |                            |
                 V                            |
            APIs/Endpoints               Load Balancer
                                               |
                                               V
                                          Database

  • Complete True of False Questions
question T or F
Open standards and protocols allow many different developers to build software and hardware for the internet True
IETF is a task force used to enforce laws and keep certain people out of the internet False
Routes are determined in advance and are not flexible False
A protocol is an agreed upon set of rules that specify behavior of a system True
UDP guarantees transfers and is faster False
WWW is the internet False
HTTP is protocol used by WWW True

Fault Tolerance

Watch both Daily videos for 4.2

  • Complete the network activity, summarize your understanding of fault tolerance.
    • Fault tolerance is a network’s ability to withstand disconnections. Networks use many interconnected nodes to guarantee that no one or two interrupted connections can take down a system.

Parallel and Distributed Computing

Review previous lecture on Parallel Computing and watch Daily video 4.3. Think of ways to make something in you team project to utilize Cores more effectively. Here are some thoughts to add to your story of Computers and Networks…

  • What is naturally Distributed in Frontend/Backend architecture? - Data

  • Analyze this command in Docker: ENV GUNICORN_CMD_ARGS="--workers=1 --bind=0.0.0.0:8086". Determine if there is options are options in this command for parallel computing within the server that runs python/gunicorn. Here is an article

    • this command only utilizes one worker to complete tasks, to complete more tasks at a higher speed, increase the amount of workers.

Last week we discussed parallel computing on local machine. There are many options. Here is something to get parallel computing work with a tool called Ray.

  • Review this article… Can you get parallel code on images to work more effectively? I have not tried Ray.
  • Code example from ChatGPT using squares. This might be more interesting if nums we generated to be a lot bigger.
import ray

# define a simple function that takes a number and returns its square
def square(x):
    return x * x

# initialize Ray
ray.init()

# create a remote function that squares a list of numbers in parallel
@ray.remote
def square_list(nums):
    return [square(num) for num in nums]

# define a list of numbers to square
nums = [1, 2, 3, 4, 5]

# split the list into two parts
split_idx = len(nums) // 2
part1, part2 = nums[:split_idx], nums[split_idx:]

# call the remote function in parallel on the two parts
part1_result = square_list.remote(part1)
part2_result = square_list.remote(part2)

# get the results and combine them
result = ray.get(part1_result) + ray.get(part2_result)

# print the result
print(result)