This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
notes:discrete:fall2022:projects:rle0 [2022/09/06 23:57] – [SPECIFICATIONS] dmuck | notes:discrete:fall2022:projects:rle0 [2022/09/07 22:57] (current) – [PROGRAM] abarbcal | ||
---|---|---|---|
Line 18: | Line 18: | ||
The RLE algorithm will encode this data by replacing the repeated characters with a count number and a single value. | The RLE algorithm will encode this data by replacing the repeated characters with a count number and a single value. | ||
- | < | + | < |
There are 4 a's (0x61), 2 b' | There are 4 a's (0x61), 2 b' | ||
Line 104: | Line 104: | ||
Encoder will output a file with a name equivalent to the second argument. | Encoder will output a file with a name equivalent to the second argument. | ||
- | Decode program will take one argument: | + | Decode program will take two arguments: |
<cli> | <cli> | ||
- | ./decode INFILE | + | ./decode INFILE |
- | | + | |
- | ./decode sample0.txt.rle | + | ./decode sample0.txt.rle |
</ | </ | ||
+ | The decoder should be able to read the header and find out the filename if a second argument is not given. If a second argument is given it will use the second argument instead of taking the filename from the header. | ||
Decode will output a file of similar name without the .rle extension after running your decoder. | Decode will output a file of similar name without the .rle extension after running your decoder. | ||
=====OUTPUT SPECIFICATIONS===== | =====OUTPUT SPECIFICATIONS===== | ||
Line 143: | Line 144: | ||
**NOTE:** This is not the full make check output, this is pending a full successful make check so if one is achieved feel free to delete this. | **NOTE:** This is not the full make check output, this is pending a full successful make check so if one is achieved feel free to delete this. | ||
+ | Verification adds the in/ to the input file name argument, as well as the out/ for the output file name argument. | ||
<cli> | <cli> | ||
USERNAME@lab46: | USERNAME@lab46: | ||
Line 152: | Line 153: | ||
in/ | in/ | ||
in/ | in/ | ||
+ | in/ | ||
+ | |||
+ | ================================================= | ||
+ | = PHASE 1: Decode -> Raw data verification test = | ||
+ | ================================================= | ||
+ | in/ | ||
+ | in/ | ||
+ | in/ | ||
+ | in/ | ||
+ | |||
+ | ================================================ | ||
+ | = PHASE 2: Raw -> Encode -> Decode -> Raw test = | ||
+ | ================================================ | ||
+ | in/ | ||
+ | in/ | ||
+ | in/ | ||
+ | in/ | ||
+ | |||
+ | ============================================= | ||
+ | = PHASE 3: Decode -> Raw -> Encode Raw test = | ||
+ | ============================================= | ||
+ | in/ | ||
+ | in/ | ||
+ | in/ | ||
+ | in/ | ||
</ | </ |