set opt dist to 1

This commit is contained in:
Niko Abeler 2022-11-19 21:32:21 +01:00
parent df7db9b27d
commit ebb683d3e2
2 changed files with 2 additions and 2 deletions

View File

@ -63,7 +63,7 @@ fn read_graph(file_name: &str) -> (usize, EdgeMatrix) {
} }
fn main() -> std::io::Result<()> { fn main() -> std::io::Result<()> {
const ITER: usize = 600; const ITER: usize = 5000;
const THREADS: usize = 8; const THREADS: usize = 8;
// let edges = connection_matrix(size); // let edges = connection_matrix(size);

View File

@ -12,7 +12,7 @@ pub struct MyModel {
impl MyModel { impl MyModel {
pub fn new(edges: EdgeMatrix, size: usize, iterations: usize) -> MyModel { pub fn new(edges: EdgeMatrix, size: usize, iterations: usize) -> MyModel {
let opt_dist = 1.0 / (size as f32).sqrt(); let opt_dist = 1.0;
let c = 0.1; let c = 0.1;
let mut ranks = vec![0.0; size]; let mut ranks = vec![0.0; size];
{ {