Multiple StellarPopulation instances
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- Python
- Star
- 76
- Fork
- 45
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
Because parameter state and dirtiness is specific to each instance, but the computed model is held by the module level driver object, having multiple StellarPopulation instances can cause a model to not be recomputed even though it should be (example code below) This might also cause problems with shared memory multiprocessing.
Some documentation advising only a single sps instance per program might be a good idea.
from numpy.testing import assert_allclose
import fsps
sps = fsps.StellarPopulation(zcontinuous=1, vactoair_flag=False)
pop = fsps.StellarPopulation(zcontinuous=1, vactoair_flag=False)
w1, s1 = sps.get_spectrum(tage=10.0)
w, s = pop.get_spectrum(tage=1.0)
w2, s2 = sps.get_spectrum(tage=10.0)
assert_allclose(s, s2) # this should not pass, but does
assert_allclose(s1, s2) # this should not fail, but does
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với StellarPopulation.get_spectrum và trạng thái driver ở cấp module được mô tả trong issue. Tái hiện chuỗi được cung cấp với hai instance, sau đó theo dõi cách trạng thái thay đổi của tham số và việc tính toán lại model được dùng chung. Hoàn thành khi mỗi instance trả về kết quả nhất quán với các tham số riêng của nó, bao gồm cả hai assertions trong ví dụ.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- fortran, python
- Lĩnh vực
- backend
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100