mirror of
https://github.com/bitcoinresearchkit/brk.git
synced 2026-07-31 12:43:06 -07:00
computer: simplified a bunch of things
This commit is contained in:
@@ -75,6 +75,7 @@ where
|
||||
prices,
|
||||
starting_indexes,
|
||||
height_to_market_cap,
|
||||
&utxo_cohorts.all.metrics.supply.total.sats.height,
|
||||
exit,
|
||||
)?;
|
||||
|
||||
|
||||
@@ -65,10 +65,10 @@ pub(crate) fn process_blocks(
|
||||
let height_to_first_txoutindex = &indexer.vecs.outputs.first_txoutindex;
|
||||
let height_to_first_txinindex = &indexer.vecs.inputs.first_txinindex;
|
||||
|
||||
// From transactions and inputs/outputs (via .height or .height.sum_cum.sum patterns):
|
||||
// From transactions and inputs/outputs (via .height or .height.sum_cumulative.sum patterns):
|
||||
let height_to_tx_count = &transactions.count.tx_count.height;
|
||||
let height_to_output_count = &outputs.count.total_count.sum_cum.sum.0;
|
||||
let height_to_input_count = &inputs.count.height.sum_cum.sum.0;
|
||||
let height_to_output_count = &outputs.count.total_count.sum_cumulative.sum.0;
|
||||
let height_to_input_count = &inputs.count.height.sum_cumulative.sum.0;
|
||||
// From blocks:
|
||||
let height_to_timestamp = &blocks.time.timestamp_monotonic;
|
||||
let height_to_date = &blocks.time.date;
|
||||
|
||||
@@ -1,17 +1,14 @@
|
||||
use std::time::Instant;
|
||||
|
||||
use brk_error::Result;
|
||||
use brk_types::Height;
|
||||
use brk_types::{EmptyAddressData, FundedAddressData, Height};
|
||||
use rayon::prelude::*;
|
||||
use tracing::info;
|
||||
use vecdb::{AnyStoredVec, WritableVec, Stamp};
|
||||
|
||||
use crate::distribution::{
|
||||
Vecs,
|
||||
block::{
|
||||
EmptyAddressDataWithSource, FundedAddressDataWithSource, process_empty_addresses,
|
||||
process_funded_addresses,
|
||||
},
|
||||
block::{WithAddressDataSource, process_empty_addresses, process_funded_addresses},
|
||||
state::BlockState,
|
||||
};
|
||||
|
||||
@@ -28,8 +25,8 @@ use super::super::address::{AddressTypeToTypeIndexMap, AddressesDataVecs, AnyAdd
|
||||
pub(crate) fn process_address_updates(
|
||||
addresses_data: &mut AddressesDataVecs,
|
||||
address_indexes: &mut AnyAddressIndexesVecs,
|
||||
empty_updates: AddressTypeToTypeIndexMap<EmptyAddressDataWithSource>,
|
||||
funded_updates: AddressTypeToTypeIndexMap<FundedAddressDataWithSource>,
|
||||
empty_updates: AddressTypeToTypeIndexMap<WithAddressDataSource<EmptyAddressData>>,
|
||||
funded_updates: AddressTypeToTypeIndexMap<WithAddressDataSource<FundedAddressData>>,
|
||||
) -> Result<()> {
|
||||
info!("Processing address updates...");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user