Chenguang Du

Results 2 issues of Chenguang Du

使用FileCacheQueueScheduler时,可能会出现游标的值比URL的数量要大的情况,查看了一下源代码,发现问题在这里, `@Override public synchronized Request poll(Task task) { if (!inited.get()) { init(task); } fileCursorWriter.println(cursor.incrementAndGet()); return queue.poll(); }` 在public synchronized Request poll(Task task)方法中,每次queue.poll()前都要将游标自增1,但是queue.poll()得到可能是null,这就导致了游标比文件中URL数量要大的情况,这在多线程的时候很明显。 我觉得应该加一个非空判断更准确: `public synchronized Request poll(Task task) { if(!this.inited.get())...

I noticed that there is bug in the preprocessing code for 20ng(scripts/data_20ng.py) https://github.com/adjidieng/ETM/blob/52b090b5b2fd6fcecc6d0b2c55d03a2d893b729d/scripts/data_20ng.py#L88 missing the `idx_permute ` index convert