<commit_before>namespace $.$$ {
	
	export class $mol_plot_pane extends $.$mol_plot_pane {
		
		@ $mol_mem
		dimensions() {
			const graphs = this.graphs()
			
			const next = [
				[ Number.POSITIVE_INFINITY , Number.POSITIVE_INFINITY ] ,
				[ Number.NEGATIVE_INFINITY , Number.NEGATIVE_INFINITY ] ,
			]
			
			for( let graph of graphs ) {
				const dims = graph.dimensions()
				
				if( dims[ 0 ][ 0 ] < next[ 0 ][ 0 ] ) next[ 0 ][ 0 ] = dims[ 0 ][ 0 ]
				if( dims[ 0 ][ 1 ] < next[ 0 ][ 1 ] ) next[ 0 ][ 1 ] = dims[ 0 ][ 1 ]
				if( dims[ 1 ][ 0 ] > next[ 1 ][ 0 ] ) next[ 1 ][ 0 ] = dims[ 1 ][ 0 ]
				if( dims[ 1 ][ 1 ] > next[ 1 ][ 1 ] ) next[ 1 ][ 1 ] = dims[ 1 ][ 1 ]
			}
			
			return next
		}
		
		@ $mol_mem
		size() {
			const dims = this.dimensions()
			return [
				( dims[1][0] - dims[0][0] ) || 1 ,
				( dims[1][1] - dims[0][1] ) || 1 ,
			]
		}
		
		@ $mol_mem
		dimensions_expanded() {
			const dims = this.dimensions()
			const size = this.size()
			const gap = [ 0 , 0 ]
			return [
				[ dims[0][0] - size[0] * gap[0] , dims[0][1] - size[1] * gap[1] ] ,
				[ dims[1][0] + size[0] * gap[0] , dims[1][1] + size[1] * gap[1] ] ,
			]
		}
		
		@ $mol_mem
		size_expaned() {
			const dims = this.dimensions_expanded()
			return [
				( dims[1][0] - dims[0][0] ) || 1 ,
				( dims[1][1] - dims[0][1] ) || 1 ,
			]
		}
		
		graph_hue( index : number ) {
			return ( 360 + ( this.hue_base() + this.hue_shift() * index ) % 360 ) % 360
		}
		
		@ $mol_mem
		graphs_colored() {
			const graphs = this.graphs_positioned()
			
			graphs.forEach( ( graph , index ) => {
				graph.hue = () => this.graph_hue( index )
			} )
			
			return graphs
		}
		
		size_real() {
			return [ this.width() , this.height() ]
		}
		
		view_box() {
			const size = this.size_real()
			return `0 0 ${ size[0] } ${ size[1] }`
		}
		
		@ $mol_mem
		scale_limits() {
			const size = this.size_expaned()
			const real = this.size_real()
			const left = + ( real[0] - this.gap_left() - this.gap_right() ) / size[0]
			const bottom = - ( real[1] - this.gap_top() - this.gap_bottom() ) / size[1]
			const right = 20
			const top = 20

			return [[left, right], [top, bottom]] as [[number, number], [number, number]]
		}

		@ $mol_mem
		scale_defaults() {
			return this.scale_limits()[0]
		}

		@ $mol_mem
		scale(next?: [number, number]) {
			if (next === undefined) next = this.scale_defaults()
			return new $mol_vector_2d( ...next ).limited(this.scale_limits())
		}

		@ $mol_mem
		shift_limits() {
			const [min, max] = this.dimensions_expanded()
			const [scale_x, scale_y] = this.scale()
			const [size_x, size_y] = this.size_real()

			const left = -max[0] * scale_x + size_x - this.gap_left()
			const right = -min[0] * scale_x + this.gap_right()

			const bottom = -min[1] * scale_y + size_y - this.gap_bottom()
			const top = -max[1] * scale_y + this.gap_top()

			return [[left, right], [bottom, top]] as [[number, number], [number, number]]
		}

		@ $mol_mem
		shift_defaults() {
			const dims = this.dimensions_expanded()<commit_msg>fix(plot_pane): as const<commit_after>namespace $.$$ {

	export class $mol_plot_pane extends $.$mol_plot_pane {
		
		@ $mol_mem
		dimensions() {
			const graphs = this.graphs()
			
			const next = [
				[ Number.POSITIVE_INFINITY , Number.POSITIVE_INFINITY ] ,
				[ Number.NEGATIVE_INFINITY , Number.NEGATIVE_INFINITY ] ,
			]
			
			for( let graph of graphs ) {
				const dims = graph.dimensions()
				
				if( dims[ 0 ][ 0 ] < next[ 0 ][ 0 ] ) next[ 0 ][ 0 ] = dims[ 0 ][ 0 ]
				if( dims[ 0 ][ 1 ] < next[ 0 ][ 1 ] ) next[ 0 ][ 1 ] = dims[ 0 ][ 1 ]
				if( dims[ 1 ][ 0 ] > next[ 1 ][ 0 ] ) next[ 1 ][ 0 ] = dims[ 1 ][ 0 ]
				if( dims[ 1 ][ 1 ] > next[ 1 ][ 1 ] ) next[ 1 ][ 1 ] = dims[ 1 ][ 1 ]
			}
			
			return next
		}
		
		@ $mol_mem
		size() {
			const dims = this.dimensions()
			return [
				( dims[1][0] - dims[0][0] ) || 1 ,
				( dims[1][1] - dims[0][1] ) || 1 ,
			]
		}
		
		@ $mol_mem
		dimensions_expanded() {
			const dims = this.dimensions()
			const size = this.size()
			const gap = [ 0 , 0 ]
			return [
				[ dims[0][0] - size[0] * gap[0] , dims[0][1] - size[1] * gap[1] ] ,
				[ dims[1][0] + size[0] * gap[0] , dims[1][1] + size[1] * gap[1] ] ,
			]
		}
		
		@ $mol_mem
		size_expaned() {
			const dims = this.dimensions_expanded()
			return [
				( dims[1][0] - dims[0][0] ) || 1 ,
				( dims[1][1] - dims[0][1] ) || 1 ,
			]
		}
		
		graph_hue( index : number ) {
			return ( 360 + ( this.hue_base() + this.hue_shift() * index ) % 360 ) % 360
		}
		
		@ $mol_mem
		graphs_colored() {
			const graphs = this.graphs_positioned()
			
			graphs.forEach( ( graph , index ) => {
				graph.hue = () => this.graph_hue( index )
			} )
			
			return graphs
		}
		
		size_real() {
			return [ this.width() , this.height() ]
		}
		
		view_box() {
			const size = this.size_real()
			return `0 0 ${ size[0] } ${ size[1] }`
		}
		
		@ $mol_mem
		scale_limits() {
			const size = this.size_expaned()
			const real = this.size_real()
			const left = + ( real[0] - this.gap_left() - this.gap_right() ) / size[0]
			const bottom = - ( real[1] - this.gap_top() - this.gap_bottom() ) / size[1]
			const right = 20
			const top = 20

			return [[left, right], [bottom, top]] as const
		}

		@ $mol_mem
		scale_defaults() {
			const limits = this.scale_limits()
			return [limits[0][0], limits[1][0]] as const
		}

		@ $mol_mem
		scale(next?: readonly [number, number]) {
			if (next === undefined) next = this.scale_defaults()
			return new $mol_vector_2d( ...next ).limited(this.scale_limits())
		}

		@ $mol_mem
		shift_limits() {
			const [min, max] = this.dimensions_expanded()
			const [scale_x, scale_y] = this.scale()
			const [size_x, size_y] = this.size_real()

			const left = -max[0] * scale_x + size_x - this.gap_left()
			const right = -min[0] * scale_x + this.gap_right()

			const bottom = -min[1] * scale_y + size_y - this.gap_bottom()
			const top = -max[1] * scale_y + this.gap_top()

			return [[left, right], [bottom, top]] as const
		}

		@ $mol_mem
		shift_defaults() {
			const dims = this.dimensions_expanded()
{'fraction_non_alphanumeric': 0.18311944718657452, 'fraction_numerical': 0.03241197762421849, 'mean_word_length': 2.491671453187823, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 11, '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': '6307101', 'n_tokens_mistral': 3039, 'n_tokens_neox': 2435, 'n_words': 540}