Skip to content

thaiQB/CompArch-HCMUT-251

Repository files navigation

THIS IS THE beta BRANCH, WHERE I TEST THE FINISHED CODE SENT BY MY TEAMMATES, FOR MY IMPLEMENTATION, SEE THE main-alpha BRANCH


Caution

My teammates said that this MIPS file fails all Votien's testcases, the reason is our computed values for the output signal have differences of 0.x for each values comparing to Votien's.

Update 11/11/25: I asked another guy who passed the testcases, and he said he set M = 10 for the computations, meanwhile our group set M = 3. I think that is the reason why our results have errors. But seems like we have accepted our fate, since tomorrow is already the report day 😭
Update 5/1/26: We got 10 grade omggggg!!!!!

ASSIGNMENT: FILTERING AND PREDICTION SIGNAL WITH WIENER FILTER

According to the tasks derived from the assignment's specification, this files can perform the following:

  • Read the input files input.txt and desired.txt
  • Return size error if the number of elements in 2 files are different
  • Compute the autocorrelations and cross-correlations of the input signal $x[n]$ and $d[n]$
  • Compute the output signal $y[n]$
  • Write the result to the output file output.txt

Files In This repository

  1. CA_Assignment_251_2.pdf: The specification for this large assignment
  2. CO2008_Assignment_CC04_Group08.asm: Our final source file
  3. test.cpp: A C++ file to test the result of autocorrelation and cross-correlation
  4. test.py: This served as an example for testing the computing results. The results of the .asm file is required to be the same as the .py file.
  5. Testcase folders: Folders of testcases (duh)
  6. Refs folder: A folder of references for the computation methods (believe me, I tried my best to find the ones writing the math formulas as simple as possible. Please, I'm not a mad scientist or a gifted student (how sad~) to read the advanced mathematical symbols in those MIT and MATLAB's documents 😓)
    • Gaussian.pdf: This is my teammate approach to solve the problem by hand. Based on this, he implemented the Python code (yes, the test.py file, if you're asking) and I, based on his Python code, implemented the MIPS code :v
  7. report_final.pdf: Our report document

PREQUISITES

You'll need these in order to test my work:

  1. MARS MIPS Simulator 4.5
  2. A testcase (to be honest, I still don't know what is the expected result for the output signal :v)
    • An input.txt and an output.txt files containing floating-point numbers (you can see some examples about these files in the Testcase folder are required for the test.
    • A test example can be viewed here

Warning

It is recommended to put the files above in the same directory in order to run normally.

About

Assignment - Computer Architecture - Ho Chi Minh city University of Technology - Semester 251

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors