<commit_before>IRIS.Line3DZone = IRIS.Vector3Zone.extend({
    init: function(opts) {
        opts = IRIS._setterUndef(opts, {});
        this._super(opts);
        this._start = new IRIS.Vector3(this.minX, this.minY, this.minZ);
        this._end = new IRIS.Vector3(this.maxX, this.maxY, this.maxZ);
        this._len = this._end.clone().sub(this._start);
    },
    getStep: function() {
        var len = this._len.clone();
        len.mul(Math.random());
        return len.add(this._start).mul(this.scale);
    }
});

IRIS.registerZone(IRIS.Line3DZone, 'line3D');<commit_msg>Implementation to handle random and linear step mode.<commit_after>IRIS.Line3DZone = IRIS.Vector3Zone.extend({
    init: function(opts) {
        opts = IRIS._setterUndef(opts, {});
        this._super(opts);
        this.toX = IRIS._setterUndef(opts.toX,1);
        this.toY = IRIS._setterUndef(opts.toY,1);
        this.toZ = IRIS._setterUndef(opts.toZ,1);
        this._start = new IRIS.Vector3(this.x, this.y, this.z);
        this._end = new IRIS.Vector3(this.toX, this.toY, this.toZ);
        this._len = this._end.clone().sub(this._start);
        this._stepVector = 0;
    },
    getStep: function() {
        var len = this._len.clone();
        if (this.pattern == IRIS.ZONE_PATTERN_RANDOM)
            len.mul(Math.random());
        else {
            len.mul(this._stepVector)
            this._stepVector += this.step;
        }
        return len.add(this._start).mul(this.scale);
    }
});

IRIS.registerZone(IRIS.Line3DZone, IRIS.ZONE_TYPE_LINE_3D);
{'fraction_non_alphanumeric': 0.15523932729624837, 'fraction_numerical': 0.01034928848641656, 'mean_word_length': 2.55632183908046, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5419051', 'n_tokens_mistral': 554, 'n_tokens_neox': 552, 'n_words': 79}