Code Monkey home page Code Monkey logo

j-pack's Introduction

j-pack

A Java application for compressing files with LZ77 and Huffman algorithms. A school project for an Algorithms and Data Structures course.

Documentation

Weekly reports (in Finnish)

Releases

Usage

Run from source code

./gradlew run --args='arguments'

Run .jar

java -jar jpack.jar [arguments]

Arguments: [-hu filename] [-df filename] [-de inputfile outputfile]

  • hu compress file using Huffman only
  • df compress using LZ77 + Huffman
  • de decompress a jpack compressed file

Build project

./gradlew build

Generate jar from source code

./gradlew fatJar

Generate Javadoc

./gradlew javadoc

Generate Jacoco test report

./gradlew jacocoTestReport

j-pack's People

Contributors

tjouni avatar

j-pack's Issues

Vertaisarviointi

Projekti ladattu 7.6.2019 kello 12:10

Tervehdys!

Sain tehtäväkseni arvioida kompressiotyösi. Hyvä niin, sillä teen itsekin harjoitustyön samasta aiheesta.

Ensihuomiot

Luettuani läpi toteutus- ja määrittelydokumentin, sain hyvän kuvan siitä, mitä ohjelmallasi tavoittelet. Ikävää, että olet ollut kipeänä, sillä edistyksesi muutaman ekan viikon aikana on selvästi ollut nopeaa!

Koodi

En ole kovin kummoinen koodari, mutta ohjelmakoodisi näyttää siltä, miltä tiedän hyvän koodin näyttävän. Minun on helppo seurata LZ77 toimintaa, vaikken ole sen teoriaan tutustunutkaan. Luokka-hierarkia on erittäin järkevä ja hilitty, etkä näytä tekevän mitään muistillisesti liian raskaita operaatioita.

HuffmanCompress

Rekursio huffman-koodien tuottamiseksi on todella napakka ja suoraviivainen.

LZ77Compress/Decompress

En aivan ymmärrä LZ77 toimintaa, mutta tässäkin luokassa on pelkästään hyvää ja selkeä koodia.

HuffmanTree

Sama juttu tässäkin, oma puu-totetukseni on huomattavasti sotkuisempi ja useamman kerran pitempi kuin sinun implementaatiosi, hyvää työtä!

Ohjelman toiminta

En osannut ajaa gradle-kokemattomuuttani ohjelmaasi. Kuitenkin siinä onnistuttuani, ihastelin sen tehokkuutta. Ajoin ohjelmasi Moby Dick novellilla ja sain samanasteisen kompressiotehokkuuden kuin mitä Seitsemästä Veljeksestä. Hyvää työtä!

Testaus

Testikattavuusraportti kertoo selkeää kieltä ohjelman tilasta. Testit ovat riittävän kattavia ja järkeviä. Olet ymmärrettävästi jättänyt Huffmanin testaamisen pois, kun et sitä vielä ohjelmassasi käytäkään.

Yleiset kommentit

Olet edistynyt todella hyvin, ja epäilemättä, kunhan saat keon toteutettua Huffmanin puu-tarpeisiin, niin projektisi alkaa hipomaan valmista työtä.

Ainut rakentava palautteeni työhösi ei liity niinkään koodiin, vaan ohjelman käytettävyyteen. Vaikka käyttöohjetta ei olekaan tarvinnut vielä tehdä, ohjelmasi ajoa hieman hidasti se, että minun täytyi itse selvittää ja lisätä build.gradle tiedostoon rivit: apply plugin: 'application' mainClassName = 'jpack.Main'
Hyvää työtä kertakaikkiaan! Monet ratkaisuistasi saavat oman kompressio-ohjelmani näyttämään vitsiltä. Onnea ja menestystä loppukurssille!
Yt. Akseli

Code review

Most of the changes since the last code review seem to be focused around UI improvements, so I shall be focusing on that as well. For the most part, the program was easy to use, since all I had to do was to run gradlew run and follow the usage instructions. The only problem with the usage instructions was the fact that it expected me to be running program via a jar file, but I couldn't get gradlew jar to produce a .jar with the correct main class, so instead I had to google how to pass arguments through gradlew run. It would be nice if the README included some information on how you'd like the user to run the program.

Otherwise the usability of the program was just fine, and I managed to compress and decompress the test file using both algorithms without any issues. The jar issue may very well just be me using gradle incorrectly, so as long as it works on your system, it's nothing to worry about.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.