Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use correct DataFrame object when calculating number of partitions #783

Merged
merged 8 commits into from
Dec 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

- Renamed variable in pipeline.finalise to better reflect what the dataframe represents (sources_df -> associations_df) [#787](https://github.com/askap-vast/vast-pipeline/pull/787)
- Fixed typo in variable name ("assoications") [#787](https://github.com/askap-vast/vast-pipeline/pull/787)
- Fix partition calculation from wrong DataFrame object [#783](https://github.com/askap-vast/vast-pipeline/pull/783)
- Fix processing config parameters not displaying in web interface [#782](https://github.com/askap-vast/vast-pipeline/pull/782)
- Fix incorrect zenodo links [#780](https://github.com/askap-vast/vast-pipeline/pull/780)

Expand All @@ -30,6 +31,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

- [#788](https://github.com/askap-vast/vast-pipeline/pull/788): feat, fix: Speed up forced fitting code by using numba-fied forced_phot code and reordering some calculations
- [#787](https://github.com/askap-vast/vast-pipeline/pull/787): fix: Optimise associations merge and minor variable name updates
- [#783](https://github.com/askap-vast/vast-pipeline/pull/783): fix: Fix partition calculation from wrong DataFrame object
- [#782](https://github.com/askap-vast/vast-pipeline/pull/782): fix: Fix processing config parameters not displaying in web interface
- [#780](https://github.com/askap-vast/vast-pipeline/pull/780): docs: Fix incorrect zenodo links

Expand Down
2 changes: 1 addition & 1 deletion vast_pipeline/pipeline/new_sources.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def parallel_get_rms_measurements(
}

n_workers, n_partitions = calculate_workers_and_partitions(
df,
out,
n_cpu=n_cpu,
max_partition_mb=max_partition_mb
)
Expand Down
2 changes: 1 addition & 1 deletion vast_pipeline/pipeline/pairs.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def calculate_measurement_pair_metrics(
"""

n_workers, n_partitions = calculate_workers_and_partitions(
df,
df.set_index('source'),
n_cpu=n_cpu,
max_partition_mb=max_partition_mb
)
Expand Down
2 changes: 1 addition & 1 deletion vast_pipeline/utils/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ def calculate_n_partitions(df, n_cpu, partition_size_mb=15):

partition_size_mb = int(np.ceil(mem_usage_mb / n_partitions))

logger.debug("Using %d partions of %dMB", n_partitions, partition_size_mb)
logger.debug("Using %d partitions of %dMB", n_partitions, partition_size_mb)

return n_partitions

Expand Down
Loading